How can I execute a function, when admin changes the user role of a user?
I have two user roles: one is agent and the other one is client .
My need is that when admin changes the user role of client to agent, I need to execute a specific function.
In this function I need to get the all content and meta fields of user by getting the user id.