// DefaultLoginCheck checks whether the user has to be activated before
// authentication or not.
DefaultLoginCheck checks whether the user has to be activated before
authentication or not.
// DefaultLoginCheck checks whether the user has to be activated before // authentication or not .
func DefaultLoginCheck(open bool) LoginCheck {
	return func(_ context.Context, usr User) error {
		if !open && !usr.ExposeCore().IsActivated() {
			return ErrNotActivated
		}
		return nil
	}
}
func DefaultLoginCheck ( open bool ) LoginCheck { return func ( _ context . Context , usr User ) error { if ! open && ! usr . ExposeCore ( ) . IsActivated ( ) { return ErrNotActivated } return nil } }
DefaultLoginCheck checks whether the user has to be activated before
authentication or not.
DefaultLoginCheck checks whether the user has to be activated before authentication or not .