fix postMessage domain restriction to pass on error