Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions augurScan/src/error-chain.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
export const errorChainIncludes = (error: unknown, names: ReadonlySet<string>): boolean => {
const seen = new Set<unknown>()
let current: unknown = error
while (typeof current === 'object' && current !== null && !seen.has(current)) {
seen.add(current)
if ('name' in current && typeof current.name === 'string' && names.has(current.name)) return true
current = 'cause' in current ? current.cause : undefined
}
return false
}
884 changes: 884 additions & 0 deletions augurScan/src/indexer-runtime.ts

Large diffs are not rendered by default.

Loading
Loading