Skip to content

Commit

Permalink
fix isMakerBreachedMaintenanceMarginLog after change in log
Browse files Browse the repository at this point in the history
  • Loading branch information
crispheaney committed Oct 20, 2023
1 parent 3937a48 commit 78a09c1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/bots/common/txLogParse.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,15 @@ export function isMakerBreachedMaintenanceMarginLog(
log: string
): string | null {
const regex =
/^maker \(([1-9A-HJ-NP-Za-km-z]+)\) breached maintenance requirements.*$/;
/^maker \(([1-9A-HJ-NP-Za-km-z]+)\) breached (maintenance|fill) requirements.*$/;
const match = log.match(regex);

return match ? match[1] : null;
}

export function isTakerBreachedMaintenanceMarginLog(log: string): boolean {
const match = log.match(
new RegExp('.*taker breached maintenance requirements.*')
new RegExp('.*taker breached (maintenance|fill) requirements.*')
);

return match !== null;
Expand Down

0 comments on commit 78a09c1

Please sign in to comment.