validateTokenCSRF($token)) { // Activate theme activateTheme($themeDirectory); // Redirect Redirect::page('themes'); } } Log::set(__FILE__.LOG_SEP.'Error occurred when trying to validate the tokenCSRF.', ALERT_STATUS_FAIL); Log::set(__FILE__.LOG_SEP.'Token in install theme ['.$token.']', ALERT_STATUS_FAIL); Session::destroy(); Redirect::page('login');