Variable contentTypesToShow in LeftMenuLinkContainer is always undefined #2353
Labels
issue: bug
Issue reporting a bug
severity: medium
If it breaks the basic use of the product but can be worked around
status: confirmed
Confirmed by a Strapi Team member or multiple community members
Informations
What is the current behavior?
The variable contentTypesToShow is always undefined.
strapi/packages/strapi-admin/admin/src/components/LeftMenuLinkContainer/index.js
Line 44 in c8d5fd1
Steps to reproduce the problem
Create a project, add log to print the value
What is the expected behavior?
It should give contentTypes as shown in /admin/layout
Suggested solutions
After reading the source codes, it probably relates to the following line:
strapi/packages/strapi-admin/admin/src/containers/AdminPage/saga.js
Line 19 in c8d5fd1
Previously,
layout
is assigned by:And it looks like this: { layout: { contentTypesToShow: {...} } } and hence
get(layout, 'layout.contentTypesToShow');
retrieves correct value.Since shorthand property is used, "layout" is no longer needed in path.
The text was updated successfully, but these errors were encountered: