class UserRepository
Methods
Find a user by ID, optionally making sure it is visible to a certain user, or throw an exception.
Find a user by username, optionally making sure it is visible to a certain user, or throw an exception.
Find a user by an identification (username or email).
Get the ID of a user with the given username.
Find users by matching a string of words against their username, optionally making sure they are visible to a certain user.
Scope a query to only include records that are visible to a user.
Details
at
line 21
Builder
query()
Get a new query builder for the users table.
at
line 36
User
findOrFail(int $id, User $actor = null)
Find a user by ID, optionally making sure it is visible to a certain user, or throw an exception.
at
line 53
User
findOrFailByUsername($username, User $actor = null)
Find a user by username, optionally making sure it is visible to a certain user, or throw an exception.
at
line 66
User|null
findByIdentification(string $identification)
Find a user by an identification (username or email).
at
line 79
User|null
findByEmail(string $email)
Find a user by email.
at
line 91
int|null
getIdForUsername(string $username, User $actor = null)
Get the ID of a user with the given username.