use myimages as an object instead of an array