/** * Returns an instance of class (singleton pattern implementation). * * @return OW_Feedback */ public static function getInstance() { if (self::$classInstance === null) { self::$classInstance = new self(); } return self::$classInstance; }
private function getThemeDtoByKeyInParamsArray($params) { if (!empty($params["key"])) { $themeDto = $this->themeService->findThemeByKey(trim($params["key"])); } if (!empty($themeDto)) { return $themeDto; } $this->feedback->error(OW::getLanguage()->text("admin", "manage_themes_theme_not_found")); $this->redirect(OW::getRouter()->urlForRoute("admin_themes_choose")); }
/** * Returns global feedback object. * * @return OW_Feedback */ public static function getFeedback() { return OW_Feedback::getInstance(); }