diff --git a/site/component/Header/index.jsx b/site/component/Header/index.jsx index c540bdadfc..299ca928f5 100644 --- a/site/component/Header/index.jsx +++ b/site/component/Header/index.jsx @@ -43,7 +43,7 @@ export default class Header extends React.Component { } handleSearch(value) { - this.props.history.push({ pathname: value }); + this.context.router.push({ pathname: value }); } handleSelectFilter(value, option) { @@ -137,3 +137,7 @@ export default class Header extends React.Component { ); } } + +Header.contextTypes = { + router: React.PropTypes.object.isRequired, +};