lastfm: loves import

This commit is contained in:
Philipp Wolfer 2023-11-26 12:56:27 +01:00
parent 1249238d3a
commit 406e150987
No known key found for this signature in database
GPG key ID: 8FDF744D4919943B
5 changed files with 57 additions and 6 deletions

View file

@ -49,7 +49,10 @@ func Authenticate(service string, backend models.Backend, db storage.Database, c
}
conf := authenticator.OAuth2Strategy(redirectURL).Config()
tokenSource := auth.NewDatabaseTokenSource(db, service, &conf, token)
authenticator.OAuth2Setup(tokenSource)
err = authenticator.OAuth2Setup(tokenSource)
if err != nil {
return needAuth, err
}
}
return needAuth, nil
}