preventing broken staff view by ensuring that role ID is replaced by the actual staff rid.