Fixed bug where images didn't load correctly