Skip to content
This repository was archived by the owner on Dec 9, 2025. It is now read-only.

Conversation

@skyhit
Copy link
Contributor

@skyhit skyhit commented Jun 11, 2020

No description provided.

@skyhit skyhit requested a review from cwdcwd June 11, 2020 02:44
if(expirySeconds!=null)
jwt.setExpirySeconds(expirySeconds);
List<String> roles = new ArrayList<String>();
List<String> roles = new ArrayList<>();
Copy link

Choose a reason for hiding this comment

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

Reason for taking out this type-checking?

Copy link

Choose a reason for hiding this comment

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

.

Copy link
Contributor Author

@skyhit skyhit Jun 12, 2020

Choose a reason for hiding this comment

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

@mtwomey just clean up, Java is language feature means this part can be omitted, since we have List<String> https://docs.oracle.com/javase/tutorial/java/generics/genTypeInference.html

Copy link

@mtwomey mtwomey left a comment

Choose a reason for hiding this comment

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

Kindly review comments

* Represents the update scopes for machine token validation.
*/
public static final String[] UpdateScopes = {"update:user_profiles", "all:user_profiles"};

Copy link

Choose a reason for hiding this comment

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

Is there a place we could put these so they're not hard coded?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@mtwomey not sure I understand this, you want to make these configurable like using environment files?

Copy link
Contributor

Choose a reason for hiding this comment

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

@skyhit I'm not a fan of magic strings either. We're going to accept the PR but can you follow up with another PR to pull all the magic strings out to the config and inject via env vars with defaults?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@cwdcwd ok, I will make my suggestion.

// to handle fake social account, adding below check before verifiying from auth0
if(profile.getContext()==null) {
profile.setContext(new HashMap<String, String>());
profile.setContext(new HashMap<>());
Copy link

Choose a reason for hiding this comment

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

Removed type-checking?

Copy link
Contributor Author

@skyhit skyhit Jun 12, 2020

Choose a reason for hiding this comment

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

@mtwomey just clean up, Java 8's new language feature means this part can be omitted. https://docs.oracle.com/javase/tutorial/java/generics/genTypeInference.html

if(expirySeconds!=null)
jwt.setExpirySeconds(expirySeconds);
List<String> roles = new ArrayList<String>();
List<String> roles = new ArrayList<>();
Copy link

Choose a reason for hiding this comment

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

.

@mtwomey mtwomey merged commit b26b8da into dev Jun 12, 2020
@eisbilir eisbilir deleted the add_m2m_token_support_for_user_endpoints branch November 10, 2023 20:55
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants