Browse Source

Add 404 exception to remote service.

Former-commit-id: 953c61e52764dbb100f01b19399515e230fe295d
Former-commit-id: b867fdc358c972522e74def500515f704bf5f5ca
pull/17/head
James South 12 years ago
parent
commit
a7bdfa4975
  1. 5
      src/ImageProcessor.Web/Services/RemoteImageService.cs

5
src/ImageProcessor.Web/Services/RemoteImageService.cs

@ -15,6 +15,7 @@ namespace ImageProcessor.Web.Services
using System.IO;
using System.Net;
using System.Threading.Tasks;
using System.Web;
using ImageProcessor.Web.Helpers;
@ -159,6 +160,10 @@ namespace ImageProcessor.Web.Services
buffer = memoryStream.ToArray();
}
else
{
throw new HttpException(404, "No image exists at " + uri);
}
}
}
}

Loading…
Cancel
Save