Use wfScript() instead of global in a few places

Change-Id: I3bb8eb52508e0f0ba40a889b400b0fc303311e29