Setting a player-named character as a password answer?

So I'm making a game in which you name your protagonist, and then later on there is a password-locked door in which the password needed is the player's name. I'm using the strategy of setting aside an actor slot as the password, so i was wondering if there was a way to make a conditional branch that did something like "if actor 0001's name is equal to 0002's name".

Does anyone know how to do this?
Code:
Conditional Branch: Script: $gameActors.actor(1).name() === $gameActors.actor(2).name()
If that gives you an error, try using just .name for both without the ()
It worked perfectly, thank you so much!

Original thread: https://forums.rpgmakerweb.com/threads/setting-a-player-named-character-as-a-password-answer.52464/