Partial edits for refactor of db, committing prior to trying to merge in the api branch