Fix connection to DB