Fix error catching on image showing