Skip to content

Commit

Permalink
Throw exception when full MARC record is missing.
Browse files Browse the repository at this point in the history
  • Loading branch information
demiankatz committed Jan 9, 2024
1 parent 42d26e9 commit 4493589
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ public function getRawMarcData()
break;
}
}
if (!isset($this->fields[$preferredMarcField])) {
throw new \Exception('Missing MARC data in record ' . $this->getUniqueId());
}
return trim($this->fields[$preferredMarcField]);
}

Expand Down

0 comments on commit 4493589

Please sign in to comment.