react-native-firebase/lib/modules/auth/providers/TwitterAuthProvider.js

26 lines
522 B
JavaScript
Raw Normal View History

2017-11-17 14:22:46 +00:00
/**
* @flow
* TwitterAuthProvider representation wrapper
*/
2017-11-23 17:29:40 +00:00
import type { AuthCredential } from '../../../types';
const providerId = 'twitter.com';
export default class TwitterAuthProvider {
constructor() {
throw new Error('`new TwitterAuthProvider()` is not supported on the native Firebase SDKs.');
}
2017-11-17 14:22:46 +00:00
static get PROVIDER_ID(): string {
return providerId;
}
2017-11-17 14:22:46 +00:00
static credential(token: string, secret: string): AuthCredential {
return {
token,
secret,
providerId,
};
}
}