Fixed typo and added more db methods