Program: 145568
Project: 145568
Buggy source:
public Object executeServerModuleMethod(final String aModuleName,final String aMethodName,final JsArrayString aParams,final JavaScriptObject onSuccess) throws Exception {
  String[] convertedParams=new String[aParams.length()];
  for (int i=0; i < aParams.length(); i++)   convertedParams[i]=param(PlatypusHttpRequestParams.PARAMS_ARRAY,aParams.get(i));
  String query=params(param(PlatypusHttpRequestParams.TYPE,String.valueOf(Requests.rqExecuteServerModuleMethod)),param(PlatypusHttpRequestParams.MODULE_NAME,aModuleName),param(PlatypusHttpRequestParams.METHOD_NAME,aMethodName),params(convertedParams));
  if (onSuccess != null) {
    startRequest(API_URI,query,null,RequestBuilder.GET,new ResponseCallbackAdapter(){
      @Override public void doWork(      XMLHttpRequest aResponse) throws Exception {
        String responseType=aResponse.getResponseHeader("String_Node_Str");
        if (responseType != null) {
          responseType=responseType.toLowerCase();
          if (responseType.contains("String_Node_Str") || responseType.contains("String_Node_Str")) {
            Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(Utils.jsonParse(aResponse.getResponseText())));
          }
 else {
            Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(aResponse.getResponseText()));
          }
        }
 else {
          Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(aResponse.getResponseText()));
        }
      }
    }
,null);
    return null;
  }
 else {
    XMLHttpRequest2 executed=syncRequest(API_URI,query,null,RequestBuilder.GET);
    if (executed != null) {
      String responseType=executed.getResponseHeader("String_Node_Str");
      if (responseType != null) {
        responseType=responseType.toLowerCase();
        if (responseType.contains("String_Node_Str") || responseType.contains("String_Node_Str")) {
          return Utils.toJs(Utils.jsonParse(executed.getResponseText()));
        }
 else {
          return Utils.toJs(executed.getResponseText());
        }
      }
 else {
        return Utils.toJs(executed.getResponseText());
      }
    }
 else {
      return null;
    }
  }
}

Fixed version (ground truth):
public Object executeServerModuleMethod(final String aModuleName,final String aMethodName,final JsArrayString aParams,final JavaScriptObject onSuccess) throws Exception {
  String[] convertedParams=new String[aParams.length()];
  for (int i=0; i < aParams.length(); i++)   convertedParams[i]=param(PlatypusHttpRequestParams.PARAMS_ARRAY,aParams.get(i));
  String query=params(param(PlatypusHttpRequestParams.TYPE,String.valueOf(Requests.rqExecuteServerModuleMethod)),param(PlatypusHttpRequestParams.MODULE_NAME,aModuleName),param(PlatypusHttpRequestParams.METHOD_NAME,aMethodName),params(convertedParams));
  if (onSuccess != null) {
    startRequest(API_URI,query,null,RequestBuilder.GET,new ResponseCallbackAdapter(){
      @Override public void doWork(      XMLHttpRequest aResponse) throws Exception {
        String responseType=aResponse.getResponseHeader("String_Node_Str");
        if (responseType != null) {
          responseType=responseType.toLowerCase();
          if (responseType.contains("String_Node_Str") || responseType.contains("String_Node_Str")) {
            Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(Utils.jsonParse(aResponse.getResponseText())));
          }
 else {
            Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(aResponse.getResponseText()));
          }
        }
 else {
          Utils.executeScriptEventVoid(onSuccess,onSuccess,Utils.toJs(aResponse.getResponseText()));
        }
      }
    }
,null);
    return null;
  }
 else {
    XMLHttpRequest2 executed=syncRequest(API_URI,query,ResponseType.Default);
    if (executed != null) {
      if (executed.getStatus() == Response.SC_OK) {
        String responseType=executed.getResponseHeader("String_Node_Str");
        if (responseType != null) {
          responseType=responseType.toLowerCase();
          if (responseType.contains("String_Node_Str") || responseType.contains("String_Node_Str")) {
            return Utils.toJs(Utils.jsonParse(executed.getResponseText()));
          }
 else {
            return Utils.toJs(executed.getResponseText());
          }
        }
 else {
          return Utils.toJs(executed.getResponseText());
        }
      }
 else       throw new Exception(executed.getStatusText());
    }
 else {
      return null;
    }
  }
}