fixed issue with pause-resume