cuthbertLab / music21j

Javascript port of music21 -- Toolkit for Computational Musicology
Other
142 stars 41 forks source link

Stream.getElementsByOffset() should return clone #240

Closed vanderstel closed 4 months ago

vanderstel commented 4 months ago

Bug

Stream.getElementsByOffset() was returning an iterator without the offset filter added.

Fix

With https://github.com/cuthbertLab/music21j/pull/239, addFilter() now returns a clone of the original iterator. This PR rewrites Stream.getElementsByOffset() to return the clone, not the original.