aboutsummaryrefslogtreecommitdiffstats
path: root/packages/sol-trace
diff options
context:
space:
mode:
Diffstat (limited to 'packages/sol-trace')
-rw-r--r--packages/sol-trace/src/revert_trace_subprovider.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/sol-trace/src/revert_trace_subprovider.ts b/packages/sol-trace/src/revert_trace_subprovider.ts
index d36cba08b..fa065cfcb 100644
--- a/packages/sol-trace/src/revert_trace_subprovider.ts
+++ b/packages/sol-trace/src/revert_trace_subprovider.ts
@@ -106,8 +106,8 @@ export class RevertTraceSubprovider extends TraceCollectionSubprovider {
continue;
}
- const fileIndexByFileName = _.invert(contractData.sources);
- const fileIndex = _.parseInt(fileIndexByFileName[sourceRange.fileName]);
+ const fileNameToFileIndex = _.invert(contractData.sources);
+ const fileIndex = _.parseInt(fileNameToFileIndex[sourceRange.fileName]);
const sourceSnippet = getSourceRangeSnippet(sourceRange, contractData.sourceCodes[fileIndex]);
if (sourceSnippet !== null) {
sourceSnippets.push(sourceSnippet);