use right variable for pause

fixes #2049