refactoring and cleanup
documented classes and modules
meets all Rails conventions