correcting code to a define module