/** * @see Action::readParameters() */ public function readParameters() { parent::readParameters(); if (isset($_GET['fileID'])) { $this->fileID = intval($_GET['fileID']); } $this->sourceFile = new SourceFile($this->fileID); if (!$this->sourceFile->fileID) { throw new IllegalLinkException(); } if (!$this->sourceFile->canDownload()) { throw new PermissionDeniedException(); } }