update the code to get the role entity