umbraco/Umbraco-CMS — pull request #520 by Jeavon (2014-10-28 08:56:36+00:00)
Title: Fix for U4-5698 - EntityService.GetObjectType throws for deleted Id's

For example

var test = ApplicationContext.Current.Services.EntityService.GetObjectType(3333333);

This fix works but I suspect it has wider implications and there is probably a better method of handling it as I doubt we want to be modifying PetaPoco.cs, maybe even try/catch in the GetObjectType method, over to @Shandem and @sitereactor....?