aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrandon Mathis <brandon@imathis.com>2011-08-16 00:41:57 -0400
committerBrandon Mathis <brandon@imathis.com>2011-08-16 00:43:07 -0400
commita5f87149fec051cbc395bc645de71469361f8c78 (patch)
tree1f34578d66b50ddea8ee08f10fa331ab995eae6d
parent33112a65a8f3bc18843593386beaa3aaa3695f92 (diff)
downloadmy_new_personal_website-a5f87149fec051cbc395bc645de71469361f8c78.tar.xz
my_new_personal_website-a5f87149fec051cbc395bc645de71469361f8c78.zip
expand_urls now correctly matches urls pointing to the root directory, allowing / to be replaced with /subdir/ if site is configured with a different root directory
-rw-r--r--plugins/octopress_filters.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/octopress_filters.rb b/plugins/octopress_filters.rb
index 67118b53..9c94f0e2 100644
--- a/plugins/octopress_filters.rb
+++ b/plugins/octopress_filters.rb
@@ -58,7 +58,7 @@ module OctopressFilters
# Replaces relative urls with full urls
def expand_urls(input, url='')
url ||= '/'
- input.gsub /(\s+(href|src)\s*=\s*["|']{1})(\/[^\"'>]+)/ do
+ input.gsub /(\s+(href|src)\s*=\s*["|']{1})(\/[^\"'>]*)/ do
$1+url+$3
end
end