fix bug when single image doesnt display