Treating the case when the module_inverse returns None