Skip to content

v2.0.0-beta2 - Auth::isLoggedIn()

Pre-release
Pre-release
Compare
Choose a tag to compare
@jasny jasny released this 27 Dec 11:31
· 117 commits to master since this release
bf34ca7
  • Auth::user() throws an AuthException if not logged in.
  • Added method Auth::isLoggedIn().

The user() method always returns a user and never null, as
it typical to use Auth::user()->doSomething() while assuming
a user is logged in due to access control on the page. Having
the method return null is an issue when using static code
analysis.