diff --git a/addon/src/test-support/get-page-title.ts b/addon/src/test-support/get-page-title.ts index edc430b..6918ca9 100644 --- a/addon/src/test-support/get-page-title.ts +++ b/addon/src/test-support/get-page-title.ts @@ -5,7 +5,7 @@ export function getPageTitle(doc: Document) { // In Fastboot context we get 2 title elements if we don't remove one from app/index.html // In real world applications, it is mandatory to remove from app/index.html // We are keeping both for sake for testing browser and fastboot scenarios - let element = [ + const element = [ ...(doc || window.document).querySelectorAll('head title'), ].pop();