Skip to content

Instantly share code, notes, and snippets.

@hiranya911
Created December 29, 2019 00:03
Show Gist options
  • Save hiranya911/011886f8128cc0b736781905ae8dee50 to your computer and use it in GitHub Desktop.
Save hiranya911/011886f8128cc0b736781905ae8dee50 to your computer and use it in GitHub Desktop.
// Specify the unique ID of the tenant to authenticate.
firebase.auth().tenantId = 'TENANT_ID1';
// Usual Firebase sign-in logic. User will be authenticated
// with tenant-specific identity providers.
firebase.auth().signInWithEmailAndPassword(email, password)
.then((result) => {
const user = result.user;
// user.tenantId is set to 'TENANT_ID1'.
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment