use whatever global, not just window (issue #8)
1.1.1