Skip to content
This repository has been archived by the owner on Jun 17, 2022. It is now read-only.

Commit

Permalink
only show warning if there is a row
Browse files Browse the repository at this point in the history
  • Loading branch information
kspearrin committed Oct 11, 2018
1 parent 90f7233 commit 9fa99f3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/importers/baseImporter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,10 @@ export abstract class BaseImporter {
});
if (result.errors != null && result.errors.length > 0) {
result.errors.forEach((e) => {
// tslint:disable-next-line
console.warn('Error parsing row ' + e.row + ': ' + e.message);
if (e.row != null) {
// tslint:disable-next-line
console.warn('Error parsing row ' + e.row + ': ' + e.message);
}
});
}
return result.data && result.data.length > 0 ? result.data : null;
Expand Down

0 comments on commit 9fa99f3

Please sign in to comment.