trying to fix a bug with image not loading