Skip to content

Commit

Permalink
Merge pull request #391 from protofire/fix-missing-callback
Browse files Browse the repository at this point in the history
  • Loading branch information
leolower authored Apr 24, 2020
2 parents 1a91ada + af91711 commit 6e093b5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/common/LinkableComponent/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ export default function LinkableComponent({ children, id }) {
(fn: Function) => {
if (initialized) return

fn()
if (fn) {
fn()
}

setInitialized(true)
},
[initialized],
Expand Down

0 comments on commit 6e093b5

Please sign in to comment.