Created by: phistuck
The trigger was detected only if the target element had an ID attribute and it matched the value of either the href or data-target of the trigger. This adds another minimal effort to the detection - if Collapse is triggered by clicking on a trigger, add it to the trigger list. Test case -
<a data-toggle="collapse" data-target="[data-me="1"]">Trigger</a><div data-me="1" class="collapse"></div>