Skip to content

Commit

Permalink
feat(firebase-x): add getCurrentUser (#3389)
Browse files Browse the repository at this point in the history
* feat(firebase-x): add getCurrentUser

add getCurrentUser method. fixes #3356

* Update index.ts

* resolve merge conflict

* resolve merge conflicts

Co-authored-by: Daniel Sogl <mytechde@outlook.com>
  • Loading branch information
akshaydwivedi29 and danielsogl authored May 15, 2020
1 parent 9892ce7 commit 809e5ac
Showing 1 changed file with 51 additions and 0 deletions.
51 changes: 51 additions & 0 deletions src/@ionic-native/plugins/firebase-x/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,48 @@ export interface IChannelOptions {
visibility?: -1 | 0 | 1;
}

export interface FirebaseUser {
/**
* ID token
*/
idToken?: string;

/**
* Provider ID
*/
providerId?: string;

/**
* UID
*/
uid?: string;

/**
* photo url
*/
photoUrl?: string;

/**
* phone number
*/
phoneNumber?: string;

/**
* is email verified
*/
emailIsVerified?: boolean;

/**
* email
*/
email?: string;

/**
* name
*/
name?: string;
}

/**
* @name Firebase X
* @description
Expand Down Expand Up @@ -128,6 +170,15 @@ export class FirebaseX extends IonicNativePlugin {
return;
}

/**
* Get the current FCM user.
* @return {Promise<FirebaseUser | string>}
*/
@Cordova()
getCurrentUser(): Promise<FirebaseUser | string> {
return;
}

/**
* Get notified when a token is refreshed.
* @return {Observable<any>}
Expand Down

0 comments on commit 809e5ac

Please sign in to comment.