Having trouble getting member roles from 'wix-users'

I’ve been trying to make a page that displays different elements based on different users’ member roles. Currently, I have two member roles: the default “Member” and a new role “Sponsors”. I’ve gotten the member roles using the wix-users module as such.

import wixUsers from 'wix-users'; 

$w.onReady(function () { 
	//TODO: write your page related code here... 
	var roleName; 
	let currentUser = wixUsers.currentUser; 

	currentUser.getRoles() 
	.then( (roles) => { 
    var firstRole = roles[0]; 
    roleName = firstRole.name;                // "Role Name" 
	console.log(roleName); 
    var roleDescription = firstRole.description;  // "Role Description" 
  }).catch( 
      onFailure() 
  ); 

  

  if(roleName === "Sponsors"){ 
	  $w('#text13').show(); 
  } 

}); 

I know that the promise from getRoles() is resolving based on my debugging, and the console.log(roleName) is logging “Sponsors” to the console correctly when I’m logged in.

However, it seems that the if statement of if(roleName === “Sponsors”) will not run, whatever I do. What am I doing wrong? Thank you in advance!

Hello, I need the same thing. Is it already solved? If yes, can you give me the code?