Fix undefined method .path on nil

Hi,

I got a undefined method call on .nil at line 106 of spring/application.rb.
After deeper investigation I've found out that my Gemfile didn't have sinatra, but other gem required it.
That caused spring to fail loading of rails app and crash.

This simple change checks that Rails.application is there before accessing it.

With this change it raises proper message that required file is not there.