Skip to content
This repository has been archived by the owner on Apr 20, 2024. It is now read-only.

Commit

Permalink
Loosened constraints on Loginable to make user type a little more fle…
Browse files Browse the repository at this point in the history
…xible
  • Loading branch information
rasmusebbesen committed May 14, 2019
1 parent 8aa0467 commit 36f698e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Sources/Sugar/Authentication/Loginable.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import Vapor
public protocol Loginable {

/// Payload containing the information required to perform a login.
associatedtype Login: HasReadablePassword
associatedtype Login

/// Used to perform any pre-login steps such as validation.
///
Expand Down Expand Up @@ -33,7 +33,8 @@ extension Loginable {

extension Loginable where
Self: PasswordAuthenticatable,
Self.Login: HasReadableUsername
Self.Login: HasReadableUsername,
Self.Login: HasReadablePassword
{
/// Default implementation that uses functionality provided by `PasswordAuthenticatable`.
/// See `Loginable`.
Expand Down

0 comments on commit 36f698e

Please sign in to comment.