Made pause working. Fixes #2.