summaryrefslogtreecommitdiff
path: root/lib/coderay/helpers/plugin.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/coderay/helpers/plugin.rb')
-rw-r--r--lib/coderay/helpers/plugin.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/coderay/helpers/plugin.rb b/lib/coderay/helpers/plugin.rb
index 2b47d8e..938d1a8 100644
--- a/lib/coderay/helpers/plugin.rb
+++ b/lib/coderay/helpers/plugin.rb
@@ -235,7 +235,7 @@ protected
# Raises +ArgumentError+ for all other objects, or if the
# given String includes non-alphanumeric characters (\W).
def validate_id id
- if id.is_a? Symbol
+ if id.is_a? Symbol or id.nil?
id
elsif id.is_a? String
if id[/\w+/] == id