does no longer shit itself when the database is empty