From 62684da16e58ea5c34ada3a23a12c2223898aacd Mon Sep 17 00:00:00 2001 From: Phillip Kessels Date: Sat, 7 Dec 2024 10:16:02 +0000 Subject: [PATCH] fix: nextjs version comparison (#1415) Co-authored-by: Pangratios Cosma --- packages/nextjs/src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nextjs/src/index.ts b/packages/nextjs/src/index.ts index 3d32bb70..38235fda 100644 --- a/packages/nextjs/src/index.ts +++ b/packages/nextjs/src/index.ts @@ -195,7 +195,7 @@ function addServerExternalPackagesOption(config) { const nextJsVersion = getNextJsVersionInstalled(); if (nextJsVersion) { - if (+nextJsVersion[0] >= 14 && +nextJsVersion[1] >= 3) { + if ((+nextJsVersion[0] === 14 && +nextJsVersion[1] >= 3) || +nextJsVersion[0] > 14) { log('debug', 'adding serverExternalPackages option with value ["@honeybadger-io/js"]') config.serverExternalPackages = ['@honeybadger-io/js'] }