redirect inside try/catch block – bug?
Notice: This thread is very old.
- Budry
- Member | 88
Hi,
I found strange behavior if I catching redirect()
I have two codes
public function adctionDefault()
{
$this->redirect('Sign:');
}
public function adctionDefault()
{
try {
$this->redirect('Sign:');
} catch (\Exception $e) {
dump($e);
die();
}
}
First redirect is correct but twice return Nette\AbortException. Why?
This is bug or expected behavior?