diff --git a/packages/win32-api/src/util/user32/GetWindowTextW.ts b/packages/win32-api/src/util/user32/GetWindowTextW.ts index 37829713..41316946 100644 --- a/packages/win32-api/src/util/user32/GetWindowTextW.ts +++ b/packages/win32-api/src/util/user32/GetWindowTextW.ts @@ -34,6 +34,6 @@ export async function GetWindowTextW( const len2 = Math.min(resLength, nMaxCount - 1) const title = bufferToString(buf, len2) - return title ?? '' + return title || '' } diff --git a/packages/win32-api/test/root.config.ts b/packages/win32-api/test/root.config.ts index 10b96156..17a7c9d6 100644 --- a/packages/win32-api/test/root.config.ts +++ b/packages/win32-api/test/root.config.ts @@ -1,6 +1,7 @@ import { join } from 'node:path' import { genCurrentDirname } from '@waiting/shared-core' + import { isWinLocaleChinese } from './util.js' @@ -19,7 +20,7 @@ export interface TestConfig { testDir: string testAppDir: string CI: boolean - isWinChinese : boolean + isWinChinese: boolean } const testAppDir = join(testDir, 'fixtures', 'base-app')