You're right on each "StateChange" it will reevaluate. So I turn it back to its original version or we try to add a check before the <code>this.detected = true;</code> line ?