Skip to content

Commit

Permalink
Change hydrated stores error to be a list of actions
Browse files Browse the repository at this point in the history
  • Loading branch information
cookiefission committed Nov 19, 2016
1 parent 3c0f9a2 commit 1095759
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions node_package/src/StoreRegistry.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,11 @@ export default {
const storeKeys = Array.from(hydratedStores.keys()).join(', ');

if (storeKeys.length === 0) {
const msg = 'There are no stores hydrated and you are requesting the store ' +
`${name}. This can happen if you are server rendering and either \nyou do not call ` +
"redux_store near the top of your controller action's view (not the layout) " +
'and before any call to react_component \nor you do not render ' +
'redux_store_hydration_data anywhere on your page';
const msg = `There are no stores hydrated and you are requesting the store ${name}.\n` +
'This can happen if you are server rendering and either: \n' +
"1) You do not call redux_store near the top of your controller action's " +
'view (not the layout) and before any call to react_component \n' +
'2) You do not render redux_store_hydration_data anywhere on your page';
throw new Error(msg);
}

Expand Down

0 comments on commit 1095759

Please sign in to comment.