adding isInterrupted control