f-miyu / Plugin.FirebaseAuth

MIT License
61 stars 26 forks source link

Retrieve all users #21

Closed vhugogarcia closed 4 years ago

vhugogarcia commented 4 years ago

Thanks for this great plugin! I am wondering if it is possible to retrieve all users using the plugin.

Thanks in advance

actopozipc commented 4 years ago

I highly doubt that this is possible, whats the use case?

vhugogarcia commented 4 years ago

It could be useful for counting the total of users allowed in a system for a particular service.

actopozipc commented 4 years ago

This doesn't sound effective since you would have to fetch the data of all users to get a single integer-value. Imagine having a big database with a few thousand or even more entrys.
I would recommend you to make a seperate realtime-database with an count-entry that gets refreshed/edited with every registration.

vhugogarcia commented 4 years ago

Thanks @actopozipc . I implemented that approach and it worked very good. Thanks for the recommendation. :)