wrapped everything in an IIFE, so globals are gone