In this post
I noticed that user.Role was retrieved incorrectly. It now seems more like a feature than a bug. Cause of it is the messy naming inside Wix of roles. Below an example:
So an Admin for the Wix Editor becomes an automatic Member when this admin logs into his own Published site with these credentials: a Contact Row with status Member/Admin is aut. created. In Wix code he is a Member.
Same for Owner: he becomes automatically a contact as Member/Owners, in Wix Code he is the Admin.
Confused? You´re not the only one. And there is also a place (cannot no longer find where), where the Admin/Member is called a Contributor.
Hope this helps others save a lot of time.