fixed db issue when deploying