update util.js, add three more utility method