Hello!
I tried to do as you recommended. But I use not tinyDb but iToo store. It didn't work. I need the application to constantly
receive notifications from Firebase. And if, for example, an activated message comes, the application should notify about it with a sound signal and show a notification. When the user opens the application, there should be an inscription that it was activated (this information also comes from Firebase). Similarly, if a "deactivated" message comes from Firebase, another sound signal will be played and the notification will be different. and again, if the user is in the application, it will display what exactly was deactivated (information from Firebase). All this should work even if the application is closed or running in the background. That is why itoo is used, which creates a background service that does not let the application die