rails3.x patch
Merge pull request #3 from ifad/rails3

rails3.x patch