fixed missing database connection