Skip to content

Commit 1433e0f

Browse files
committed
Less code
1 parent 8fe0531 commit 1433e0f

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

packages/core/src/utils/prepareEvent.ts

+1-5
Original file line numberDiff line numberDiff line change
@@ -174,16 +174,12 @@ export function applyDebugIds(event: Event, stackParser: StackParser): void {
174174
// Build a map of filename -> debug_id
175175
const filenameDebugIdMap = getFilenameToDebugIdMap(stackParser);
176176

177-
if (!filenameDebugIdMap) {
178-
return;
179-
}
180-
181177
try {
182178
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
183179
event!.exception!.values!.forEach(exception => {
184180
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
185181
exception.stacktrace!.frames!.forEach(frame => {
186-
if (frame.filename) {
182+
if (filenameDebugIdMap && frame.filename) {
187183
frame.debug_id = filenameDebugIdMap.get(frame.filename);
188184
}
189185
});

0 commit comments

Comments
 (0)