using a js to get a field from users collection
In users collection i've added a field called "categoria" actually if you are a user i need to open the user page and if you are a contractor you'll go to contractor page.
but i'm not able to create a js to extract this information.