refactor db reloading function organization, and added if handler for if result is 0 on queries, try reloading the db and return again.