firebase

Flutter Firebase Authentication currentUser() returns null

一世执手 提交于 2021-02-09 11:10:42
问题 This is about Flutter Firebase Authentication plugin. I am trying to send a verification email after creating a new user, but sendEmailVerification() internally uses currentUser(). This looks like a bug to me, but just in case, I am posting a question to stackoverflow. The error is the same on Android and IOS. First two lines return FirebaseUser. The third returns null. Forth, if third is commented throws a null reference error. Thanks, Boris user = await _auth.createUserWithEmailAndPassword

Flutter Firebase Authentication currentUser() returns null

一个人想着一个人 提交于 2021-02-09 11:09:12
问题 This is about Flutter Firebase Authentication plugin. I am trying to send a verification email after creating a new user, but sendEmailVerification() internally uses currentUser(). This looks like a bug to me, but just in case, I am posting a question to stackoverflow. The error is the same on Android and IOS. First two lines return FirebaseUser. The third returns null. Forth, if third is commented throws a null reference error. Thanks, Boris user = await _auth.createUserWithEmailAndPassword

Firestore rules: How do I allow access to a subcollection depending on a field of the document that contains it?

不羁的心 提交于 2021-02-09 10:58:05
问题 I am writing a small program in react that manages a league of sorts. The problem I have is how do I allow access (read, write) to the matchdays of a league for the correct user. The matchdays are named "matchday-1", "matchday-2", and so on, and are collections of documents (the matches), and are subcollections inside the league. My firebase structure looks like this basically: leagues(collection) -> league(document) -> matchday-n(collection) -> match-m(document) where n and m are numbers.

How to write to a variable from within the Firebase getDocument function (Swift)

人走茶凉 提交于 2021-02-09 07:08:02
问题 I want to read a document, get a field from that document, and set a variable to that field's value I expected my variable declared outside the Firebase getDocument function to be written to. The actual results are that the variable is being written to within the Firebase getDocument function but outside the function it is empty. Here's what I have tried: [1]: Modifying variable within firebase function - this didn't work for me because I can't translate it well with my current Swift skills

Storing a text file in Firestore's text field removes line breaks

丶灬走出姿态 提交于 2021-02-09 07:05:36
问题 I am trying to store a CSV file in a text field inside Cloud Firestore. However Firestore is stripping out all line breaks and storing the entire CSV file as a single line. The Firestore Data Types documentation does not say anything about a restriction on the type of characters that can be stored other than they should be UTF-8: Up to 1,048,487 bytes (1 MiB - 89 bytes). Only the first 1,500 bytes of the UTF-8 representation are considered by queries. Is there a documented restriction? If

Storing a text file in Firestore's text field removes line breaks

白昼怎懂夜的黑 提交于 2021-02-09 07:03:09
问题 I am trying to store a CSV file in a text field inside Cloud Firestore. However Firestore is stripping out all line breaks and storing the entire CSV file as a single line. The Firestore Data Types documentation does not say anything about a restriction on the type of characters that can be stored other than they should be UTF-8: Up to 1,048,487 bytes (1 MiB - 89 bytes). Only the first 1,500 bytes of the UTF-8 representation are considered by queries. Is there a documented restriction? If

Storing a text file in Firestore's text field removes line breaks

江枫思渺然 提交于 2021-02-09 07:00:55
问题 I am trying to store a CSV file in a text field inside Cloud Firestore. However Firestore is stripping out all line breaks and storing the entire CSV file as a single line. The Firestore Data Types documentation does not say anything about a restriction on the type of characters that can be stored other than they should be UTF-8: Up to 1,048,487 bytes (1 MiB - 89 bytes). Only the first 1,500 bytes of the UTF-8 representation are considered by queries. Is there a documented restriction? If

Callback generates “TypeError: this is undefined” in Angular2/Firebase

天涯浪子 提交于 2021-02-09 02:45:31
问题 I'm trying to understand what is gong on here and why I'm getting an error if I call a function a certain way and not getting the error when i call the function a different way. Here is the way that produces the error first: player.service.ts file in the @Injectable i have private roomsRef: Firebase; constructor() { this.roomsRef = new Firebase("https://xxx.firebaseio.com/rooms"); } postGameActions(roomId: string) { console.log("post game actions start on " + roomId); //error on below 'this'

Exception in HostObject::get(propName:RNfirebase)

痴心易碎 提交于 2021-02-08 23:36:53
问题 I am learning how to implement Firestore with react-native(Android). Then, I found 'react-native-firebase' and stuck in this exception. Error:Exception in HostObject::get(propName:RNFirebase): java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/firebase/FirebaseApp; I already setup firebase in my gradle (ref.https://firebase.google.com/docs/android/setup/?authuser=0) Firebase database's rule rules_version = '2'; service cloud.firestore { match /databases/{database}/documents {

Salt/Hash for Firebase Simple Login?

扶醉桌前 提交于 2021-02-08 23:36:14
问题 Firebase offers 'Simple Login' in which email/password is used for authentication. Does anyone know if firebase salts and hashes the password before storing it? I imagine that firebase would know enough to do so, but I just wanted to make sure, because I could not find anything on this after an hour of searching. Anticipated follow up: If firebase in fact does not salt+hash the passwords, would the Simple Login work if I took the user's password, salted+hashed, and passed it onto firebase to