look at marker's popup state before removing it from the map
modified comment
Merge pull request #428 from mWater/issue427

Issue427