code: private String checkVarReq(final Request request,
                               final UtilActionForm form) throws Throwable {
      Collection<String> avs = request.getReqPars("setappvar");
      if (avs == null) {
        return null;
      }
  
      HashMap<String, String> appVars = getAppVars(request);
  
      for (String reqpar: avs) {
        int start;
  
        if (reqpar.endsWith("}")) {
          start = reqpar.indexOf('{');
        } else if (reqpar.endsWith(")")) {
          start = reqpar.indexOf('(');
        } else {
          return "badRequest";
        }
  
        if (start < 0) {
          return "badRequest";
        }
  
        String varName = reqpar.substring(0, start);
        String varVal = reqpar.substring(start + 1, reqpar.length() - 1);
  
        if (varVal.length() == 0) {
          varVal = null;
        }
  
        if (!setAppVar(varName, varVal, appVars)) {
          return "badRequest";
        }
      }
  
      form.setAppVarsTbl(appVars);
  
      return null;
    }
docs: Check for action setting a variable
  We expect the request parameter to be of the form<br/>
  setappvar=name(value) or <br/>
  setappvar=name{value}<p>.
  Currently we're not escaping characters so if you want both right
  terminators in the value you're out of luck - actually we cheat a bit
  We just look at the last char and then look for that from the start.
  
  @param request  Needed to locate session
  @param form     Action form
  @return String  forward to here. null if no error found.
  @throws Throwable