Fixed databaseExists method to create db first time through.