From 5776fa3fcff2c93491e95c261d98af3cebf2cac9 Mon Sep 17 00:00:00 2001 From: Dan Abramov Date: Fri, 20 Jul 2018 16:50:43 +0100 Subject: [PATCH] Update www warning shim (#13244) --- .../forks/{warning.www.js => warningWithoutStack.www.js} | 0 packages/shared/lowPriorityWarning.js | 2 +- scripts/rollup/forks.js | 4 ++-- 3 files changed, 3 insertions(+), 3 deletions(-) rename packages/shared/forks/{warning.www.js => warningWithoutStack.www.js} (100%) diff --git a/packages/shared/forks/warning.www.js b/packages/shared/forks/warningWithoutStack.www.js similarity index 100% rename from packages/shared/forks/warning.www.js rename to packages/shared/forks/warningWithoutStack.www.js diff --git a/packages/shared/lowPriorityWarning.js b/packages/shared/lowPriorityWarning.js index 299d306aae..993cdc7df7 100644 --- a/packages/shared/lowPriorityWarning.js +++ b/packages/shared/lowPriorityWarning.js @@ -39,7 +39,7 @@ if (__DEV__) { lowPriorityWarning = function(condition, format, ...args) { if (format === undefined) { throw new Error( - '`warningWithoutStack(condition, format, ...args)` requires a warning ' + + '`lowPriorityWarning(condition, format, ...args)` requires a warning ' + 'message argument', ); } diff --git a/scripts/rollup/forks.js b/scripts/rollup/forks.js index 680f5f0709..3bd99dafce 100644 --- a/scripts/rollup/forks.js +++ b/scripts/rollup/forks.js @@ -150,12 +150,12 @@ const forks = Object.freeze({ }, // This logic is forked on www to blacklist warnings. - 'shared/warning': (bundleType, entry) => { + 'shared/warningWithoutStack': (bundleType, entry) => { switch (bundleType) { case FB_WWW_DEV: case FB_WWW_PROD: case FB_WWW_PROFILING: - return 'shared/forks/warning.www.js'; + return 'shared/forks/warningWithoutStack.www.js'; default: return null; }