Skip to content

VenUserProvider

class Vendidit\AuthServer\Laravel\VenUserProvider Source: src/VenUserProvider.php

UserProvider implementing both patterns from AUTH-PHP-LARAVEL-DESIGN §4.4:

Pattern A (stateless) — no model configured. Guard receives null and falls back to VenAuthUser::fromPrincipal(). No DB query.

Pattern B (composable) — Eloquent model configured. retrieveById() does a single find($id) and the consuming app’s existing User model gains role/permission accessors via the HasVenAuth trait.