Update for latest rails and more modern conventions.
Remove unnecessary file
Add support for specifying object