Fix bug with role

Critical bug fix on accessGranted field always returning the first
checkbox which is hr, the second highest.