Formatting

This commit is contained in:
Antoine Gersant 2018-11-11 12:10:09 -08:00
parent c1c70d4fbf
commit ed81d24b7b
2 changed files with 1 additions and 7 deletions

View file

@ -234,7 +234,6 @@ fn auth(
credentials: Json<AuthCredentials>,
mut cookies: Cookies,
) -> Result<Json<AuthOutput>, errors::Error> {
if !user::auth::<DB>(&db, &credentials.username, &credentials.password)? {
bail!(errors::ErrorKind::IncorrectCredentials)
}

View file

@ -60,12 +60,7 @@ where
let mut scrobbler = Scrobbler::new(LASTFM_API_KEY.into(), LASTFM_API_SECRET.into());
let auth_response = scrobbler.authenticate_with_token(token.to_string())?;
user::lastfm_link(
db,
username,
&auth_response.name,
&auth_response.key,
)
user::lastfm_link(db, username, &auth_response.name, &auth_response.key)
}
pub fn unlink<T>(db: &T, username: &str) -> Result<(), errors::Error>