Possible bug in visibility condition