The patch for bug 1101100, in converting this code to be asynchronous and distributed, accidentally dropped the check for `data` being null; this patch restores it, and adds a regression test.