changed incorrect "request" argument to "resource" in in util.js