Wrapped publishing in a promise