I modified the email template for "reset password". If the user is out of tenant scope on Identity Planform - the template works fine. But when the user is in tenant scope - the template not working.
User out of scope:
IDP: https://i.stack.imgur.com/CNO8S.png
Email: https://i.stack.imgur.com/7B4ra.png
User in scope of tenant:
IDP: https://i.stack.imgur.com/Q42EP.png
Email: https://i.stack.imgur.com/6dB6o.png
export const resetPassword = (email) => async (dispatch) => {
try {
const userSnapshot = await firebase.db.collection(USER_DATA_COLLECTION).where('email', '==', email).get();
firebase.auth.tenantId = userSnapshot.docs[0].data().tenantId;
return await firebase.doResetPassword(email);
} catch (e) {
console.log(e);
}
};