diff options
author | Simon Rettberg | 2015-08-11 14:20:48 +0200 |
---|---|---|
committer | Simon Rettberg | 2015-08-11 14:20:48 +0200 |
commit | f21e45a68de632d741109b6d003268027bcbfc0d (patch) | |
tree | 0c875e911f398cae371a008fea2f3bf4588da503 /dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java | |
parent | [client] lecture wizard stuff (state, removed old bool, added date/time parsi... (diff) | |
download | tutor-module-f21e45a68de632d741109b6d003268027bcbfc0d.tar.gz tutor-module-f21e45a68de632d741109b6d003268027bcbfc0d.tar.xz tutor-module-f21e45a68de632d741109b6d003268027bcbfc0d.zip |
[server] Changed whoami(): return WhoamiInfo
Diffstat (limited to 'dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java')
-rw-r--r-- | dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java index 4392a249..cd622197 100644 --- a/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java +++ b/dozentenmodulserver/src/main/java/org/openslx/bwlp/sat/thrift/ServerHandler.java @@ -46,6 +46,7 @@ import org.openslx.bwlp.thrift.iface.TransferInformation; import org.openslx.bwlp.thrift.iface.TransferStatus; import org.openslx.bwlp.thrift.iface.UserInfo; import org.openslx.bwlp.thrift.iface.Virtualizer; +import org.openslx.bwlp.thrift.iface.WhoamiInfo; import org.openslx.sat.thrift.version.Version; public class ServerHandler implements SatelliteServer.Iface { @@ -154,8 +155,9 @@ public class ServerHandler implements SatelliteServer.Iface { } @Override - public UserInfo whoami(String userToken) throws TAuthorizationException { - return SessionManager.getOrFail(userToken); + public WhoamiInfo whoami(String userToken) throws TAuthorizationException { + UserInfo user = SessionManager.getOrFail(userToken); + return new WhoamiInfo(user, User.isSuperUser(user), User.canListImages(user)); } @Override |