util: bug fix for internal functions inside of lib/util.js