diff --git a/packages/neon/neon/lib/src/platform/platform.dart b/packages/neon/neon/lib/src/platform/platform.dart index 8c541890..d4e53fd6 100644 --- a/packages/neon/neon/lib/src/platform/platform.dart +++ b/packages/neon/neon/lib/src/platform/platform.dart @@ -17,6 +17,10 @@ abstract interface class NeonPlatform { /// /// Required to be called before accessing [NeonPlatform.instance]. static Future setup() async { + if (_platform != null) { + return; + } + if (Platform.isAndroid) { _platform = const AndroidNeonPlatform(); } else if (Platform.isLinux) {