From 350dfa65fe2289aa3b35d69abb7566cc50e3e4f4 Mon Sep 17 00:00:00 2001 From: Rob Miller Date: Mon, 2 Sep 2013 19:20:39 +0100 Subject: [PATCH] Fix bug when purging a URL without a path --- lib/varnisher/purger.rb | 2 ++ lib/varnisher/version.rb | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/varnisher/purger.rb b/lib/varnisher/purger.rb index 6f03b9f..767a1fe 100644 --- a/lib/varnisher/purger.rb +++ b/lib/varnisher/purger.rb @@ -77,6 +77,8 @@ def send hostname = Varnisher.options['hostname'] || @host port = Varnisher.options['port'] + @path = '/' if @path.nil? || @path == '' + begin http = Net::HTTP.new(hostname, port) response = http.request(@request_method.new(@path)) diff --git a/lib/varnisher/version.rb b/lib/varnisher/version.rb index a493bbf..ddd1a91 100644 --- a/lib/varnisher/version.rb +++ b/lib/varnisher/version.rb @@ -1,3 +1,3 @@ module Varnisher - VERSION = '1.0.beta.5' + VERSION = '1.0.beta.6' end