Fixed multiple co9nnections to db error