Skip to content
This repository has been archived by the owner on May 9, 2019. It is now read-only.

Change single-user lookups by ID in the web-gateway to use the UserService #145

Closed
TimMoore opened this issue Aug 8, 2017 · 1 comment
Closed
Assignees

Comments

@TimMoore
Copy link
Contributor

TimMoore commented Aug 8, 2017

There are a few places in web-gateway that look up a user by looping through nav.getUsers() and checking for a matching user ID. The current user is also looked up from the same list, and passed when creating a new Nav

With the changes in #131, this list of users is incomplete and eventually consistent, so this won't always work.

The following places in the code should be changed to stop using nav.getUsers(), and instead use userService.getUser(userId) to look up the user instead:

Note that, because service calls are asynchronous, you'll now need to use the CompletionStage API. You might find it helpful to refactor the existing controller methods to extract small parts into helper methods.

At the end of this change, the only thing left using nav.getUsers() should be the list of users that displays in the navigation menu.

This should also fix #144. Please be sure to test manually to verify this.

This was referenced Aug 8, 2017
@TimMoore
Copy link
Contributor Author

Fixed by #143

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

No branches or pull requests

2 participants