Have grunt correctly add the closure

this fixes the lack of closures that was causing the namespace pollution in #374 #375 seems to be related