http://stackoverflow.com/questions/10843297/throwing-an-error-in-jquerys-deferred-object