enclosed all script in a closure