Exception: QuickShort::DuplicatePrefix

Inherits:
StandardError
  • Object
show all
Defined in:
lib/quick_short/duplicate_prefix.rb

Instance Method Summary collapse

Constructor Details

#initialize(prefix) ⇒ DuplicatePrefix

When trying to register the same key twice



6
7
8
9
# File 'lib/quick_short/duplicate_prefix.rb', line 6

def initialize(prefix)
  klass = QuickShort.short_id_prefixes[prefix]
  super "Duplicate prefix: #{prefix} (already assigned to #{klass.name})"
end