converted module to use localvars class