publish: couple fixes

generated from commit 9e690f26be001d1c197f2c4307c970e21cab60d2