If there is no neighboring view controller, reset the ivar state to avoid issues when to swiping side to side without releasing.