fix(collapse): Prevent consecutive transitions

Previously, there would be a case where the two transitions would run
as the cancel would asynchronously invoke the reject handler of the
transition which would set the currTransition to undefined even when
the currTransition has been replaced with a new transition.
chore(collapse): Tidy up code duplication
Merge pull request #1293 from chrisirhc/bootstrap3_collapse-fixes

Bootstrap3 collapse consecutive transition fix and tidy up