-
Notifications
You must be signed in to change notification settings - Fork 131
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
91297ee
commit 6d49ab7
Showing
2 changed files
with
23 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
package com.auth0.json.mgmt.users; | ||
|
||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties; | ||
import com.fasterxml.jackson.annotation.JsonInclude; | ||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import com.fasterxml.jackson.annotation.*; | ||
|
||
import java.util.HashMap; | ||
import java.util.Map; | ||
|
||
@SuppressWarnings({"unused", "WeakerAccess"}) | ||
@JsonIgnoreProperties(ignoreUnknown = true) | ||
|
@@ -21,6 +22,21 @@ public class Identity { | |
private String accessToken; | ||
@JsonProperty("profileData") | ||
private ProfileData profileData; | ||
private Map<String, Object> values; | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
lbalmaceda
Author
Contributor
|
||
|
||
public Identity() { | ||
values = new HashMap<>(); | ||
} | ||
|
||
@JsonAnySetter | ||
void setValue(String key, Object value) { | ||
values.put(key, value); | ||
} | ||
|
||
@JsonAnyGetter | ||
public Map<String, Object> getValues() { | ||
return values; | ||
} | ||
|
||
@JsonProperty("connection") | ||
public String getConnection() { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Is it the right place? Aren't custom properties stored within
ProfileData
?Also I think it would be good to add same mechanism to
User
model, because, when signing up with social provider, entire profile is stored as a root entity.