diff --git a/packages/react-instantsearch-core/src/core/__tests__/createConnector.js b/packages/react-instantsearch-core/src/core/__tests__/createConnector.js index e9a1b246e5..03956f35e8 100644 --- a/packages/react-instantsearch-core/src/core/__tests__/createConnector.js +++ b/packages/react-instantsearch-core/src/core/__tests__/createConnector.js @@ -590,7 +590,7 @@ describe('createConnector', () => { expect(onSearchParameters).toHaveBeenCalledTimes(1); expect(onSearchParameters).toHaveBeenCalledWith( expect.any(Function), - context, + { ais: context }, { ...props, contextValue: context } ); }); diff --git a/packages/react-instantsearch-core/src/core/createConnector.tsx b/packages/react-instantsearch-core/src/core/createConnector.tsx index 693b919088..fecc5cfe03 100644 --- a/packages/react-instantsearch-core/src/core/createConnector.tsx +++ b/packages/react-instantsearch-core/src/core/createConnector.tsx @@ -140,7 +140,10 @@ export function createConnectorWithoutContext( if (connectorDesc.getSearchParameters) { this.props.contextValue.onSearchParameters( connectorDesc.getSearchParameters.bind(this), - this.props.contextValue, + { + ais: this.props.contextValue, + multiIndexContext: this.props.indexContextValue, + }, this.props ); }