publish: edited lazy load function

generated from commit 6dde0ce74fb01b46d1490c3065916dca961da274