[WIP] Rails 4 Port

Fix #2