optimize: removed use of the module() function and use of lua tables

optimize: removed use of the module() function and use of lua tables