Update elasticsearch.rb

If the host is not intialized it will throw an exception on line 380