Created
February 12, 2016 16:23
-
-
Save samsamm777/5b5d4b0b03c372a383ec to your computer and use it in GitHub Desktop.
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
/** | |
* Return the current user from the config object, if its present. | |
* | |
* @return {User} | |
*/ | |
public getCurrentUser(): User { | |
var _json = { | |
username: "sam", | |
name: "Sam Hudson", | |
roles: [ | |
"USER" | |
], | |
groups: [ | |
'group a' | |
] | |
}; | |
return new User(_json.username, _json.name, _json.roles, _json.groups); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment