Added in check for deleted image