__construct(Community $community = null)
sign_in(string $username, string $password)
Try to authenticate a user with a username and password.
This function always returns a plain array. The first item in that array (index 0) contains a
value that indicates if the login was successful (if that value is (bool)true. If it wasn't, it
contains a string that indicates the failure reason (
Find a user by email address or community.
Tries to find a user that is part of the specified community, or any other community if a match for
the current community can't be found. It checks both the username and email fields of users, and
returns a plain database object of the user if any match was found, otherwise it returns