Fixed memory leak by having Mods store their own value, so that its
automatically garbage collected.