lib/head_music/interval.rb in head_music-0.5.2 vs lib/head_music/interval.rb in head_music-0.5.3

- old
+ new

@@ -9,9 +9,10 @@ def self.get(semitones) @intervals ||= {} @intervals[semitones.to_i] ||= new(semitones.to_i) end + singleton_class.send(:alias_method, :[], :get) def self.named(name) name = name.to_s get(NAMES.index(name)) if NAMES.include?(name) end