Skip to content

Conversation

@israteneda
Copy link
Contributor

No description provided.

@@ -0,0 +1,19 @@
{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this functionality should be implemented as an Azure function. Why not making it part of the API?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep is a good idea, I created as azure function because the sign-up validation was part of the azure scope and azure provides some examples with azure function to validate the sign-up process with the API Connector tool, but I can create a ticket to migrate this function to the API, because now is implemented in the user flow.


context.log("Validation: ", allowedDomains.includes(domain.toLowerCase()));
// Check that the domain of the email is from a specific other tenant
if (!allowedDomains.includes(domain.toLowerCase())) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You're only looking for ioet.com as a valid domain?
I don't think so, you should find a way to make sure the token is correct and it is not expired.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

At this point we didn't have the token yet.
Since is before the user is created, and it's validating the email with which the user is trying to log in with the google provider.

Copy link
Contributor

@diegotony diegotony left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@israteneda israteneda merged commit dcf122b into master Mar 4, 2021
@diegotony diegotony deleted the TT-153-new-user-flow-for-sign-up-sign-in branch June 3, 2021 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants