aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--plugins/image_tag.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/plugins/image_tag.rb b/plugins/image_tag.rb
index 20595cb9..45670007 100644
--- a/plugins/image_tag.rb
+++ b/plugins/image_tag.rb
@@ -30,9 +30,9 @@ module Jekyll
@img['title'] = title
@img['alt'] = alt
else
- @img['alt'] = @img['title'].gsub!(/"/, '"')
+ @img['alt'] = @img['title'].gsub!(/"/, '"') if @img['title']
end
- @img['class'].gsub!(/"/, '')
+ @img['class'].gsub!(/"/, '') if @img['class']
end
super
end