Avoided useless connection to db on shutdown when there wasn't a DB instance yet.
Happened when you opened the app and immediately closed it again
Fixed bug xD