do not merge - publish.js review

how this was even possible?