fixed db auth bug