Skip to content

Commit 27ec79d

Browse files
authored
fix(sourcemaps): print source map URL instead of {source_url} on error (#1917)
1 parent 40733ff commit 27ec79d

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/utils/sourcemaps.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -953,8 +953,9 @@ impl SourceMapProcessor {
953953
bail!("Invalid embedded sourcemap in source file {source_url}");
954954
};
955955

956-
let mut sourcemap = SourceMap::from_slice(&decoded)
957-
.context("Invalid embedded sourcemap in source file {source_url}")?;
956+
let mut sourcemap = SourceMap::from_slice(&decoded).with_context(|| {
957+
format!("Invalid embedded sourcemap in source file {source_url}")
958+
})?;
958959

959960
let debug_id = sourcemap
960961
.get_debug_id()

0 commit comments

Comments
 (0)