Skip to content

Commit

Permalink
fix: no type leads to empty checkpoint (1x)
Browse files Browse the repository at this point in the history
See #167 – backport
  • Loading branch information
trieloff authored May 21, 2024
1 parent a548d3f commit 02b1f99
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const navigate = (source, type) => {
// reload: same page, navigate: same origin, enter: everything else
if (type === 'reload' || source === window.location.href) {
sampleRUM('reload', payload);
} else if (type !== 'navigate') {
} else if (type && type !== 'navigate') {
sampleRUM(type, payload); // back, forward, prerender, etc.
} else if (source && window.location.origin === new URL(source).origin) {
sampleRUM('navigate', payload); // internal navigation
Expand Down

0 comments on commit 02b1f99

Please sign in to comment.