小编Nir*_*net的帖子

如何在flutter/dart中捕获platformException?

我正进入(状态

发生异常。PlatformException (PlatformException(sign_in_canceled, com.google.android.gms.common.api.ApiException: 12501: , null))

每当我尝试在我的应用程序中弹出谷歌取消登录时。

复制步骤:

在应用程序中,当按下谷歌按钮登录时,谷歌登录页面会出现,其中包含所有可供选择的 Gmail 帐户登录或注册。

触摸弹出窗口的外部区域以取消登录,然后关闭弹出窗口。

之后代码中有平台异常说:

发生异常。PlatformException (PlatformException(sign_in_canceled, com.google.android.gms.common.api.ApiException: 12501: , null))

现在登录按钮不起作用,应用程序崩溃,

试过 try/catch - 不工作

android flutter

8
推荐指数
1
解决办法
8327
查看次数

标签 统计

android ×1

flutter ×1