add function init and attach loadModules.Post event