mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 18:12:04 +00:00
fix(Google Sheets Node): Fix for auto-range detection
This commit is contained in:
@@ -134,6 +134,10 @@ export function removeEmptyColumns(data: SheetRangeData) {
|
||||
const longestRow = data.reduce((a, b) => (a.length > b.length ? a : b), []).length;
|
||||
for (let col = 0; col < longestRow; col++) {
|
||||
const column = data.map((row) => row[col]);
|
||||
if (column[0] !== '') {
|
||||
returnData.push(column);
|
||||
continue;
|
||||
}
|
||||
const hasData = column.slice(1).some((cell) => cell || typeof cell === 'number');
|
||||
if (hasData) {
|
||||
returnData.push(column);
|
||||
|
||||
Reference in New Issue
Block a user