Firebase user registration working but not login - pls help!

Hi all, I am trying to add a login feature to my app. It is for a school project that's due on monday so I'm panicking a bit now. I have linked firebase to the app and can successfully create new users. However, when I try to login with the newly created user's username and password, nothing happens. I will post my blocks and firebase data below. I appreciate any help!!

I don't know how you set your ProjectBucket, and you did not rename your input textboxes to make their purposes clear.

So here goes anyway.

That btnLogin is probably supposed to be asking for the password of the username in textbox1.Text, but it is not changing the bucket to point to that particular user.

So the tag has to stretch from the username all the way down to its password, using the text JOIN block:

JOIN(Textbox1.Text,'/password')

(notice the '/' in front of password)
Use that as the tag in your request and in your comparison test against the inbound tag.

If that doesn't work,
(Canned Reply: ABG- Export & Upload .aia)
Export your .aia file and upload it here.

export_and_upload_aia

.

That worked! But I had to add the following to the GotValue block. Thanks for steering me on the right path!

image

Using a text Contains just for the user name might come back to burn you later on if you are asking for one of the other user attribute values from Firebase, like forename or surname.

If you are reusing this Firebase component in other contexts your tag test would have to be more specific, like

if tag = JOIN(username textbox.Text, '/password') then
if value = password.Text then ...

Makes more sense to fetch all the data for a user in one hit, then extract each item using dictionaries in the app, and do the testing in app.