forge-sql-orm 2.1.9 → 2.1.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1088,7 +1088,7 @@ async function processDDLResult(method, result) {
1088
1088
  }
1089
1089
  if (Array.isArray(result.rows)) {
1090
1090
  if (method === "execute") {
1091
- return { rows: result.rows };
1091
+ return { rows: [result.rows] };
1092
1092
  } else {
1093
1093
  const rows = result.rows.map((r) => Object.values(r));
1094
1094
  return { rows };
@@ -1103,13 +1103,9 @@ async function processExecuteMethod(query, params) {
1103
1103
  }
1104
1104
  const result = await withTimeout$1(sqlStatement.execute());
1105
1105
  await saveMetaDataToContext(result.metadata);
1106
- if (!result?.rows) {
1106
+ if (!result.rows) {
1107
1107
  return { rows: [[]] };
1108
1108
  }
1109
- if (isUpdateQueryResponse(result.rows)) {
1110
- const oneRow = result.rows;
1111
- return { rows: [oneRow] };
1112
- }
1113
1109
  return { rows: [result.rows] };
1114
1110
  }
1115
1111
  async function processAllMethod(query, params) {
@@ -1119,7 +1115,7 @@ async function processAllMethod(query, params) {
1119
1115
  }
1120
1116
  const result = await withTimeout$1(sqlStatement.execute());
1121
1117
  await saveMetaDataToContext(result.metadata);
1122
- if (!result?.rows) {
1118
+ if (!result.rows) {
1123
1119
  return { rows: [] };
1124
1120
  }
1125
1121
  const rows = result.rows.map((r) => Object.values(r));