Ensure require.main === module in workers

Fixes #9
good catch.