【问题标题】:How to reset the firebase auth account password for unity如何重置统一的firebase身份验证帐户密码
【发布时间】:2021-09-29 09:15:30
【问题描述】:

我有一个问题。我正在开发一个统一项目,在这里我使用了 firebase 数据库 系统。 我想添加一个 reset password 系统,但没有找到如何使用 unity 的文档。 如果有人知道这个系统,请告诉我。我会很高兴你。

【问题讨论】:

    标签: c# unity3d firebase-authentication


    【解决方案1】:

    sending a password reset email for Unity 的文档包含以下代码片段:

    string emailAddress = "user@example.com";
    if (user != null) {
      auth.SendPasswordResetEmailAsync(emailAddress).ContinueWith(task => {
        if (task.IsCanceled) {
          Debug.LogError("SendPasswordResetEmailAsync was canceled.");
          return;
        }
        if (task.IsFaulted) {
          Debug.LogError("SendPasswordResetEmailAsync encountered an error: " + task.Exception);
          return;
        }
    
        Debug.Log("Password reset email sent successfully.");
      });
    }
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2021-04-29
      • 1970-01-01
      • 2017-10-15
      • 2021-12-04
      • 1970-01-01
      • 2018-06-02
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多