fix: pass custom cached realpath
function to resolve
#9873
Merged
realpath
function to resolve
#9873