Add the module function to the global environment