Refactor DBHelper that handles failure of DAO creation and insertion