The line "if (progressBlock && 0 < contentStream.length)" is being replaced with "if (progressBlock)" so it looks like the check of contentStream.length has been removed, just checking that was intended?

I see what you mean, in the existing code in one method we check, one we don't.