From 25b464611b0185cb2121522521116a5be26cb05c Mon Sep 17 00:00:00 2001 From: Poff Poffenberger Date: Thu, 23 Jan 2020 15:45:05 +0000 Subject: [PATCH] test fix --- x-pack/legacy/plugins/canvas/public/legacy.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/x-pack/legacy/plugins/canvas/public/legacy.ts b/x-pack/legacy/plugins/canvas/public/legacy.ts index 15f7c0a1530ec..e399cc10ee95a 100644 --- a/x-pack/legacy/plugins/canvas/public/legacy.ts +++ b/x-pack/legacy/plugins/canvas/public/legacy.ts @@ -26,7 +26,10 @@ const shimSetupPlugins = { // When the frontend Canvas plugin is moved to NP, we can declare reporting as an optional dependency // and enable exports based on existence of the plugin. // For now, use an injected config to mimic this behavior in the meantime. - reporting: npSetup.core.injectedMetadata.getInjectedVar('reportingBrowserType') ? {} : undefined, + reporting: + npSetup.core && npSetup.core.injectedMetadata.getInjectedVar('reportingBrowserType') + ? {} + : undefined, }; const shimStartPlugins: CanvasStartDeps = {