Skip to content

Commit

Permalink
Merge pull request #677 from Stremio/feat/facebook-auth
Browse files Browse the repository at this point in the history
Facebook auth
  • Loading branch information
tymmesyde authored Jun 10, 2024
2 parents 0582dc0 + e5bf4a7 commit f74c212
Show file tree
Hide file tree
Showing 3 changed files with 206 additions and 200 deletions.
8 changes: 8 additions & 0 deletions src/types/api/request.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ impl FetchRequestParams<APIRequest> for APIRequest {
match self {
APIRequest::Auth(AuthRequest::Login { .. }) => "login".to_owned(),
APIRequest::Auth(AuthRequest::LoginWithToken { .. }) => "loginWithToken".to_owned(),
APIRequest::Auth(AuthRequest::Facebook { .. }) => "authWithFacebook".to_owned(),
APIRequest::Auth(AuthRequest::Register { .. }) => "register".to_owned(),
APIRequest::Logout { .. } => "logout".to_owned(),
APIRequest::AddonCollectionGet { .. } => "addonCollectionGet".to_owned(),
Expand Down Expand Up @@ -191,6 +192,9 @@ pub enum AuthRequest {
password: String,
gdpr_consent: GDPRConsent,
},
Facebook {
token: String,
},
LoginWithToken {
token: String,
},
Expand Down Expand Up @@ -219,6 +223,10 @@ impl fmt::Debug for AuthRequest {
.field("password", &"<SENSITIVE>")
.field("gdpr_consent", gdpr_consent)
.finish(),
Self::Facebook { token: _ } => f
.debug_struct("Facebook")
.field("token", &"<SENSITIVE>")
.finish(),
Self::LoginWithToken { token: _ } => f
.debug_struct("LoginWithToken")
.field("token", &"<SENSITIVE>")
Expand Down
Loading

0 comments on commit f74c212

Please sign in to comment.