From 7a4cc71c8588a1d471f7ca984c26216ac9a7f60e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Burzy=C5=84ski?= Date: Fri, 6 Oct 2017 03:07:51 +0200 Subject: [PATCH] Fixed quote types inconsistency in a warning message (#2297) --- src/combineReducers.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/combineReducers.js b/src/combineReducers.js index 36250e8d94..3a9d629f49 100644 --- a/src/combineReducers.js +++ b/src/combineReducers.js @@ -4,10 +4,10 @@ import warning from './utils/warning' function getUndefinedStateErrorMessage(key, action) { const actionType = action && action.type - const actionName = (actionType && `"${actionType.toString()}"`) || 'an action' + const actionDescription = (actionType && `action "${String(actionType)}"`) || 'an action' return ( - `Given action ${actionName}, reducer "${key}" returned undefined. ` + + `Given ${actionDescription}, reducer "${key}" returned undefined. ` + `To ignore an action, you must explicitly return the previous state. ` + `If you want this reducer to hold no value, you can return null instead of undefined.` )