IO#lines is deprecated

One of the deprecation warnings we're getting on the build.