support rails 4

Everything seems to work fine in my tests. The test suite passes on my local machine, though we'll see what Travis says =)