Fixed bug in showing images