Merge pull request #154 from codeodor/ar_4.0.x

Updated to work with Rails 4 release candidate 1