Avoid duplicated logic in Collector

...by implementing .run() using the context manager. Fixes #2.