remove amd modules, if module isn't loaded via amd (fixes issue #412)