My out-of-date comment's pseudo code had the logic backward.  This is the same as what was there before.