0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-20 22:42:53 -05:00

Added error logging for errors occuring during CSV import

no issue

- CSV import uses direct API calls which skips through logging error. This additional code should catch and record any internal errors
This commit is contained in:
Nazar Gargol 2020-02-07 14:33:30 +08:00
parent 69ed7cd23f
commit e57f7219e5

View file

@ -339,6 +339,9 @@ const members = {
if (inspection.reason() instanceof common.errors.ValidationError) {
duplicates = duplicates + 1;
} else {
// NOTE: if the error happens as a result of pure API call it doesn't get logged anywhere
// for this reason we have to make sure any unexpected errors are logged here
common.logging.error(inspection.reason());
invalid = invalid + 1;
}
}