Realtime DB Null values not working

A few days ago I could get a null value (or value that doesn’t exist) from my RealtimeDB database.

Now when the program tries to retrieve that variable (that doesn’t exist) it makes the entire screen white. I get “undefined” on the error message. Which typically means everything is ok.

I know it is a null value, but it was working before. This is a key part of my app to see if the user has entered data, and I don’t believe there is a way around it.

Is this a bug that recently changed?

Yes, the platform is constantly evolving and for this reason, there may be situations when something does not work. But this does not mean that the problem is only in the platform. Before using the data, you should check that it exists. So make checks for null, undefined, and the like.

I am experiencing the same issue again with my cloud variables again like my other post. Realtime db doesn’t work too

@zbk0612eip8w,

This is very frustrating. Originally, in my app I checked for a null value in my realtimedb and if it came back null then I asked for info from the user.

This doesn’t work anymore. I did a workaround and stored a local variable that let the code know “hey this user hasn’t sent this info yet”.

Again, super annoying. Hope this helps.

@ryan_hall_apps, i tried to add a label that shows the error when i did it. The error somehow suprised me:

J.a.get(…).database is not a function

I see a lot of posts about the same thing, it started happening again.

@zbk0612eip8w, I have noticed that saving a Null item as a stored variable is better than saving the variable as a local app variable.

You can see in the screen shot I call a get function to realtimeDB and store that item in a stored variable. If the stored variable is null the function still runs properly. I also don’t get any funny errors with this.