Updated the final code of the module