Skip to content

Commit

Permalink
Null check added when resolving event's priority
Browse files Browse the repository at this point in the history
  • Loading branch information
classicdocs committed Sep 24, 2024
1 parent 04bd67a commit edb3a5a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export function resolveUpdatePriority(): EventPriority {
return updatePriority;
}
const currentEvent = window.event;
if (currentEvent === undefined) {
if (currentEvent === undefined || currentEvent === null) {
return DefaultEventPriority;
}
return getEventPriority(currentEvent.type);
Expand Down

0 comments on commit edb3a5a

Please sign in to comment.