Backend: Remove redundant condition of ROLE_VIEWER (#19211)

This commit is contained in:
Masudur Rahman 2019-09-19 12:19:11 +06:00 committed by Torkel Ödegaard
parent 14f1cf29f0
commit a41a7ea656

View File

@ -36,11 +36,7 @@ func (r RoleType) Includes(other RoleType) bool {
return other != ROLE_ADMIN
}
if r == ROLE_VIEWER {
return other == ROLE_VIEWER
}
return false
return r == other
}
func (r *RoleType) UnmarshalJSON(data []byte) error {