Error Handling & Module Pattern Refactoring

Add error handling to the repositories and to the routes.

**In routes (poems.js)**:
Introduced "respond" method to standardize on the convention that unhandled errors result in an HTTP 500 error, and the error details are logged to the console on the server.

**In repositories**:
Introduced a "common_repository" module that provides a query method, to hide the machinery of the pg module. It calls pg.connect and then calls pg.query, calling done() when appropriate to release the connection to the pool. The repositories still need to check the err variable for failure, but the check is much simpler because they don't have to worry about calling done().