Fix wrong if when deleting an entry

Bad condition when deleting an entry returned `true` instead of the referer url
This commit is contained in:
Jeremy Benoist 2015-12-30 11:32:20 +01:00
parent e6a228c43b
commit e82160e5e9

View file

@ -347,7 +347,7 @@ class EntryController extends Controller
);
// don't redirect user to the deleted entry
return $this->redirect($url !== $request->headers->get('referer') ?: $this->generateUrl('homepage'));
return $this->redirect($url !== $request->headers->get('referer') ? $request->headers->get('referer') : $this->generateUrl('homepage'));
}
/**