bugfix: pass userAndRoles instead of roles

This commit is contained in:
Khalid Huseynov 2016-11-09 23:44:31 +09:00
parent 85be8b7cce
commit d7df363cd2

View file

@ -257,8 +257,10 @@ public class NotebookRestApi {
@ZeppelinApi
public Response getNoteList() throws IOException {
AuthenticationInfo subject = new AuthenticationInfo(SecurityUtils.getPrincipal());
HashSet<String> userAndRoles = SecurityUtils.getRoles();
userAndRoles.add(subject.getUser());
List<Map<String, String>> notesInfo = notebookServer.generateNotesInfo(false, subject,
SecurityUtils.getRoles());
userAndRoles);
return new JsonResponse<>(Status.OK, "", notesInfo).build();
}