UNTESTED
finished refactoring code to have all database operations contained in
their respective classes