Fix db methods.