We broke this at some point recently, and i'm not sure when. In any case, i updated some of the logic in there + added a test for it.