Commit e32bb625 by Juho Juopperi

small changes

1 parent c14d376b
......@@ -31,15 +31,16 @@ public class SessionHandler {
}
public boolean hasPermission(String target, String permission) {
RolePermission perm = RolePermission.READ;
if (permission.equals("write")) {
RolePermission perm = null;
if (permission.equalsIgnoreCase("read")) {
perm = RolePermission.READ;
} else if (permission.equals("write")) {
perm = RolePermission.WRITE;
} else if (permission.equals("execute")) {
perm = RolePermission.EXECUTE;
}
return hasPermission(target, perm);
}
public boolean hasPermission(String target, RolePermission permission) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!