mirror of
https://github.com/verdaccio/verdaccio.git
synced 2025-01-06 22:40:26 -05:00
fix: issue on refactor router
This commit is contained in:
parent
4c2fed677f
commit
19b0f47827
3 changed files with 5 additions and 4 deletions
|
@ -10,7 +10,7 @@ import classes from './packageList.scss';
|
|||
export default class PackageList extends React.Component {
|
||||
static propTypes = {
|
||||
packages: PropTypes.array,
|
||||
help: PropTypes.boolean,
|
||||
help: PropTypes.bool,
|
||||
};
|
||||
|
||||
renderPackages = () => {
|
||||
|
|
|
@ -13,7 +13,7 @@ import PackageSidebar from '../../components/PackageSidebar/index';
|
|||
export default class Detail extends Component {
|
||||
static propTypes = {
|
||||
match: PropTypes.object,
|
||||
isUserLoggedIn: PropTypes.boolean,
|
||||
isUserLoggedIn: PropTypes.bool,
|
||||
};
|
||||
|
||||
state = {
|
||||
|
@ -27,6 +27,7 @@ export default class Detail extends Component {
|
|||
params.package
|
||||
}`;
|
||||
}
|
||||
|
||||
get packageName() {
|
||||
return this.getPackageName();
|
||||
}
|
||||
|
|
|
@ -37,10 +37,10 @@ class RouterApp extends Component<IProps, IState> {
|
|||
return <HomePage isUserLoggedIn={isUserLoggedIn} packages={packages} />;
|
||||
};
|
||||
|
||||
renderDetailPage = () => {
|
||||
renderDetailPage = (routerProps: any) => {
|
||||
const { isUserLoggedIn } = this.props;
|
||||
|
||||
return <DetailPackage {...this.props} isUserLoggedIn={isUserLoggedIn} />;
|
||||
return <DetailPackage {...routerProps} isUserLoggedIn={isUserLoggedIn} />;
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue