bugfix with pause