isRemoteState check added to event listeners