fix role == None error in rights