Added a getError function to the DB class.