/** * @see Action::execute() */ public function execute() { parent::execute(); $entry = new BashEntryEditor($this->entryID); if ($entry->entryID == 0) { throw new IllegalLinkException(); } if (!$entry->isFavorite()) { $entry->favorite(); } if (!isset($_REQUEST['ajax'])) { HeaderUtil::redirect(BASHCore::getSession()->lastRequestURI, false); } }