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('\\', '/'); }