Global variables fixing

avoid implicitly variables declaration and fixing "use strict" mode