Use this method to update your own username.
        
        This method only works for users, not bots. Bot usernames must be changed via Bot Support or by recreating
        them from scratch using BotFather. To update a channel or supergroup username you can use
        :meth:`update_chat_username`.

        Args:
            username (``str`` | ``None``):
                Username to set. "" (empty string) or None to remove the username.

        Returns:
            True on success.

        Raises:
            :class:`RPCError <pyrogram.RPCError>` in case of a Telegram RPC error.

def update_username(
        self,
        username: Union[str, None]
    ) -> bool:
        """Use this method to update your own username.
        
        This method only works for users, not bots. Bot usernames must be changed via Bot Support or by recreating
        them from scratch using BotFather. To update a channel or supergroup username you can use
        :meth:`update_chat_username`.

        Args:
            username (``str`` | ``None``):
                Username to set. "" (empty string) or None to remove the username.

        Returns:
            True on success.

        Raises:
            :class:`RPCError <pyrogram.RPCError>` in case of a Telegram RPC error.
        """

        return bool(
            self.send(
                functions.account.UpdateUsername(
                    username=username or ""
                )
            )
        )