bug fix.

Set current state.