Reverse the sequence of operations to do when a switch is added - first clear all flow mods and then dispatch switch added callbacks in dispatch thread. Else we have a race condition.