Fix error because of mismatching exception message when Rails 4.1 is
installed