if (user.get_isSiteAdmin())
{
document.cookie = "licence=yes";
}
I am using user.get_isSiteAdmin() but its always giving value false I can not give permission to site site collection
Site Collection - Full Control
in AppMenifest.xml file
is there any other way to get site administrator ?
@user11869887,
Just have a test this JSOM function on my SPO environment, it works fine here.
you may need to explicitly initialize the object/properties, or it will always return false as the related property is null.
BR