/** * Construye la redireccion * * @return void */ public function make() { /* * Se guardan los headers si es que hay en la configuracion * para luego utilizarlos al construir la redireccion */ if (count($this->headers) > 0) { if (!$this->session->exists('headersInRedirect', 'redirect') || !$this->session->get('headersInRedirect', 'redirect')) { $this->session->set('redirectPath', $this->path, 'redirect'); $this->session->set('headersInRedirect', $this->headers, 'redirect'); } } header("Location: {$this->path}"); exit; }
/** * Obtiene el nombre registrado del componente o una instancia de el. * * @return mixed */ protected static function getComponent() { return \ForeverPHP\Session\SessionManager::getInstance(); }