From f5d69c3f663ff8456157da3b8638d33adfdee7da Mon Sep 17 00:00:00 2001 From: mylxsw Date: Wed, 31 Jan 2024 11:08:23 +0800 Subject: [PATCH] =?UTF-8?q?bugfix=20Web=20=E7=AB=AF=E6=97=A0=E6=B3=95?= =?UTF-8?q?=E8=BF=90=E8=A1=8C=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/helper/path.dart | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/helper/path.dart b/lib/helper/path.dart index a9b4e2ee..8e93ffb1 100644 --- a/lib/helper/path.dart +++ b/lib/helper/path.dart @@ -38,11 +38,12 @@ class PathHelper { } String get getHomePath { - Map envVars = Platform.environment; if (PlatformTool.isMacOS() || PlatformTool.isLinux()) { - return '${envVars['HOME'] ?? ''}/.aidea'.replaceAll('\\', '/'); + return '${Platform.environment['HOME'] ?? ''}/.aidea' + .replaceAll('\\', '/'); } else if (PlatformTool.isWindows()) { - return '${envVars['UserProfile'] ?? ''}/.aidea'.replaceAll('\\', '/'); + return '${Platform.environment['UserProfile'] ?? ''}/.aidea' + .replaceAll('\\', '/'); } else if (PlatformTool.isAndroid() || PlatformTool.isIOS()) { return '$documentsPath/.aidea'.replaceAll('\\', '/'); }