Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/clojure/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Reactjs react native firebase auth(本地firebase身份验证)显著确定客户端(例如,移动、web)_Reactjs_React Native_Firebase Authentication_Google Cloud Functions_React Native Firebase - Fatal编程技术网

Reactjs react native firebase auth(本地firebase身份验证)显著确定客户端(例如,移动、web)

Reactjs react native firebase auth(本地firebase身份验证)显著确定客户端(例如,移动、web),reactjs,react-native,firebase-authentication,google-cloud-functions,react-native-firebase,Reactjs,React Native,Firebase Authentication,Google Cloud Functions,React Native Firebase,我想在firebase函数中了解新用户是从哪个客户端(例如,移动、Web)注册的。我正在使用firebase客户端的方法注册一个新用户 因为我们无法控制云上的API函数。我们正在侦听Users表的onCreate事件。它有以下数据 { email: null, emailVerified: false, displayName: null, photoURL: null, phoneNumber: null, disabled: false, providerData:

我想在firebase函数中了解新用户是从哪个客户端(例如,移动、Web)注册的。我正在使用firebase客户端的方法注册一个新用户

因为我们无法控制云上的API函数。我们正在侦听Users表的onCreate事件。它有以下数据

{ email: null,
  emailVerified: false,
  displayName: null,
  photoURL: null,
  phoneNumber: null,
  disabled: false,
  providerData: [],
  customClaims: {},
  passwordSalt: null,
  passwordHash: null,
  tokensValidAfterTime: null,
  metadata: 
   UserRecordMetadata {
     creationTime: '2020-08-05T11:57:21Z',
     lastSignInTime: '2020-08-05T11:57:21Z' },
  uid: '',
  toJSON: [Function] } 

有没有办法确定Firebase Auth帐户在所有客户端平台中都是通用的。在帐户本身中,您无法使用任何标识符来了解用户是如何注册的。如果用户在Android上创建了一个帐户,那么完全可以期望他们能够使用相同的帐户和相同的凭据在web和iOS上登录


如果您想在注册时在Firebase Auth之外自行存储一些数据,您可以这样做。

不清楚“新用户从哪个客户端注册”是什么意思。请编辑问题以澄清,也许可以用一个示例和您正在使用的代码进行说明。@DougStevenson,它包含在标题中。我还编辑了正文。