fix(core): use correct name for edit route param (#3236)

This commit is contained in:
Shawn Erquhart 2020-02-11 18:28:26 -05:00 committed by GitHub
parent 249bd7ec1e
commit cfd2fed494
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -217,11 +217,11 @@ class App extends React.Component {
render={props => <Collection {...props} isSearchResults />}
/>
<RouteInCollection
path="/edit/:collectionName/:entryName"
path="/edit/:name/:entryName"
collections={collections}
render={({ match }) => {
const { collectionName, entryName } = match.params;
return <Redirect to={`/collections/${collectionName}/entries/${entryName}`} />;
const { name, entryName } = match.params;
return <Redirect to={`/collections/${name}/entries/${entryName}`} />;
}}
/>
<Route component={NotFoundPage} />