rails/rails — pull request #9818 by wangjohn (2013-03-20 02:14:20+00:00)
Title: Changed the call to .sort.last to .max when computing the migration version

Sorting then picking the last item incurs more cost than just finding the max. I've changed it so that when the current migration version is called, we use ``max`` instead of ``sort.last``.