Skip to content
This repository was archived by the owner on Dec 11, 2019. It is now read-only.

Commit dd1150d

Browse files
bridiverbsclifton
authored andcommitted
Merge pull request #9589 from evq/fix/link-hover-null-check
Add a null check for framePath in WINDOW_SET_LINK_HOVER_PREVIEW
1 parent 5a5915b commit dd1150d

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

js/stores/windowStore.js

+10-5
Original file line numberDiff line numberDiff line change
@@ -413,11 +413,16 @@ const doAction = (action) => {
413413
break
414414
}
415415
case windowConstants.WINDOW_SET_LINK_HOVER_PREVIEW:
416-
windowState = windowState.mergeIn(frameStateUtil.activeFrameStatePath(windowState), {
417-
hrefPreview: action.href,
418-
showOnRight: action.showOnRight
419-
})
420-
break
416+
{
417+
const framePath = frameStateUtil.activeFrameStatePath(windowState)
418+
if (framePath) {
419+
windowState = windowState.mergeIn(framePath, {
420+
hrefPreview: action.href,
421+
showOnRight: action.showOnRight
422+
})
423+
}
424+
break
425+
}
421426
case windowConstants.WINDOW_SET_THEME_COLOR:
422427
{
423428
const frameKey = action.frameProps.get('key')

0 commit comments

Comments
 (0)