if setImmediate is supported, use setImmediate instead of setTimeout
clean
use global.setImmediate for setImmediate conditional test
revert to type of conditional check
extract defer to a function
one line function conditional assignment
Merge pull request #4 from rolandnsharp/master

if setImmediate is supported, setImmediate, else setTimeout