From 6f5df21e5bd4795935e3bd6e6a5e418b0f96eb5e Mon Sep 17 00:00:00 2001 From: Jonah Williams Date: Fri, 13 Sep 2019 19:15:52 -0700 Subject: [PATCH] pass through --web-port in release mode too (#40465) --- packages/flutter_tools/lib/src/commands/run.dart | 2 ++ packages/flutter_tools/lib/src/device.dart | 4 +--- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/flutter_tools/lib/src/commands/run.dart b/packages/flutter_tools/lib/src/commands/run.dart index f93b4da9ce..cbb22b04a8 100644 --- a/packages/flutter_tools/lib/src/commands/run.dart +++ b/packages/flutter_tools/lib/src/commands/run.dart @@ -288,6 +288,8 @@ class RunCommand extends RunCommandBase { return DebuggingOptions.disabled( buildInfo, initializePlatform: argResults['web-initialize-platform'], + hostname: featureFlags.isWebEnabled ? argResults['web-hostname'] : '', + port: featureFlags.isWebEnabled ? argResults['web-port'] : '', ); } else { return DebuggingOptions.enabled( diff --git a/packages/flutter_tools/lib/src/device.dart b/packages/flutter_tools/lib/src/device.dart index 795471f161..3bb8cd8593 100644 --- a/packages/flutter_tools/lib/src/device.dart +++ b/packages/flutter_tools/lib/src/device.dart @@ -494,7 +494,7 @@ class DebuggingOptions { this.port, }) : debuggingEnabled = true; - DebuggingOptions.disabled(this.buildInfo, { this.initializePlatform = true }) + DebuggingOptions.disabled(this.buildInfo, { this.initializePlatform = true, this.port, this.hostname }) : debuggingEnabled = false, useTestFonts = false, startPaused = false, @@ -506,8 +506,6 @@ class DebuggingOptions { traceSystrace = false, dumpSkpOnShaderCompilation = false, verboseSystemLogs = false, - hostname = null, - port = null, observatoryPort = null; final bool debuggingEnabled;