Get Unlimited Contributor Access to the all ExamTopics Exams!
Take advantage of PDF Files for 1000+ Exams along with community discussions and pass IT Certification Exams Easily.
The g_user.hasRoleExactly() method in ServiceNow is used to check if the currently logged-in user has a specified role and no other roles. In this case, it checks if the user has the 'catalog_admin' role and no other roles.
So, the correct method call to return true only if the currently logged-in user has the 'catalog_admin' role and in no other case is g_user.hasRoleExactly('catalog_admin')
Correct answer is B, g_user.hasRoleExactly()
Please find this g_user.hasRoleOnly() client side script that you speak of in the below ServiceNow documentation. I can wait. :D
Source: https://developer.servicenow.com/dev.do#!/reference/api/utah/client/c_GlideUserAPI
Can you guys update the correct answer? So far I've seen the "correct answer" be incorrect a little too many times and I'm not even a quarter of the way through these questions....the correct answer is B!!!
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
kundgir
Highly Voted 2 years, 6 months agonsmcan
Highly Voted 2 years, 5 months agomanikanta_gnbv
Most Recent 2 weeks, 2 days agoevoken
2 months, 2 weeks agoBugPanda
4 months, 3 weeks agobrutaltea
5 months, 1 week agoLord_Korvus
7 months, 1 week agoMru9
7 months, 3 weeks agoAnu_K
8 months agostophs
11 months agoKAAAAARIM
1 year, 3 months agog_user
1 year, 4 months agoJackLopez
1 year, 4 months agorpersonal2
1 year, 5 months agoFarnous
1 year, 7 months agoGurubala
1 year, 7 months agoKrundol
1 year, 8 months ago