Authorizer<T extends Auth<AuthKeys>>.of constructor

Authorizer<T extends Auth<AuthKeys>>.of(
  1. BuildContext context
)

Implementation

factory Authorizer.of(BuildContext context) {
  try {
    return AuthProvider.authorizerOf<T>(context);
  } catch (e) {
    throw AuthProviderException(
      'No Authorizer<${AuthProvider.type}> found. '
      'Ensure AuthProvider<${AuthProvider.type}> wraps the widget tree. (cause: $e)',
    );
  }
}