Code generated while going through Rebuilding Rails (Understand Rails by Building a Ruby Web Framework). By Noah Gibbs