fixed a little bug that made global functions (setInterval etc) unavailable