Ignore:
Timestamp:
08/24/23 02:28:14 (15 months ago)
Author:
DenicaKj <dkorvezir@…>
Branches:
master
Children:
bcb4acc
Parents:
40935d3
Message:

fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/com/example/moviezone/model/Worker.java

    r40935d3 r1e7126f  
    5959    @Override
    6060    public Collection<? extends GrantedAuthority> getAuthorities() {
    61         return Collections.singletonList(Role.ROLE_ADMIN);
     61        if (position.equalsIgnoreCase("admin"))
     62            return Collections.singletonList(Role.ROLE_ADMIN);
     63        else{
     64            return Collections.singletonList(Role.ROLE_WORKER);
     65        }
    6266    }
    6367
Note: See TracChangeset for help on using the changeset viewer.