Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
constructor(
// The provider is instantiated for Sequence constructor,
// at which time we don't have information about the current
// route yet. This information is needed to determine
// what auth strategy should be used.
// To solve this, we are injecting a getter function that will
// defer resolution of the strategy until authenticate() action
// is executed.
@inject.getter(AuthenticationBindings.STRATEGY)
readonly getStrategy: Getter,
@inject.setter(AuthenticationBindings.CURRENT_USER)
readonly setCurrentUser: Setter,
) {}
constructor(
@inject(AuthenticationBindings.CURRENT_USER) private user: UserProfile,
) {}
constructor(
@inject.getter(MyAuthBindings.STRATEGY) readonly getStrategy: Getter,
@inject.setter(AuthenticationBindings.CURRENT_USER) readonly setCurrentUser: Setter,
@inject.getter(AuthenticationBindings.METADATA) readonly getMetadata: Getter,
) {}
constructor(
@inject(AuthenticationBindings.METADATA)
public metadata: AuthenticationMetadata,
@inject(MyAuthBindings.USER_PERMISSIONS)
protected checkPermissons: UserPermissionsFn,
@inject.getter(AuthenticationBindings.CURRENT_USER)
public getCurrentUser: Getter,
) {}
constructor(
@repository(CharacterRepository)
public characterRepository: CharacterRepository,
@inject(MyAuthBindings.TOKEN_SERVICE)
public jwtService: JWTService,
@inject.getter(AuthenticationBindings.CURRENT_USER)
public getCurrentUser: Getter,
) {}
constructor(
@repository(CharacterRepository)
public characterRepository: CharacterRepository,
@repository(WeaponRepository)
public weaponRepository: WeaponRepository,
@repository(ArmorRepository)
public armorRepository: ArmorRepository,
@repository(SkillRepository)
public skillRepository: SkillRepository,
//
@inject.getter(AuthenticationBindings.CURRENT_USER)
public getCurrentUser: Getter,
) {}