Fixing broken image and resource uploads