diff --git a/projects/adf-office-services-ext/src/lib/evaluators.ts b/projects/adf-office-services-ext/src/lib/evaluators.ts index 3a8dd0dcea..037df58511 100644 --- a/projects/adf-office-services-ext/src/lib/evaluators.ts +++ b/projects/adf-office-services-ext/src/lib/evaluators.ts @@ -30,6 +30,11 @@ export function canOpenWithOffice( return false; } + const extension = getFileExtension(file.entry.name); + if (!extension || !supportedExtensions[extension]) { + return false; + } + // workaround for Shared files if ( context.navigation && @@ -51,11 +56,6 @@ export function canOpenWithOffice( return false; } - const extension = getFileExtension(file.entry.name); - if (!extension || !supportedExtensions[extension]) { - return false; - } - /* if (file.entry && file.entry.aspectNames) { const checkedOut = file.entry.aspectNames.find(