some minor fixes

I have noticed that I have put io.js in javascript folder by mistake.

Also more coffeeish for loops in typescript file.