Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove 'define' : fielddefinition, because superfluous #294

Closed
bobdenotter opened this issue Jan 24, 2019 · 1 comment
Closed

Remove 'define' : fielddefinition, because superfluous #294

bobdenotter opened this issue Jan 24, 2019 · 1 comment
Assignees

Comments

@bobdenotter
Copy link
Member

@bobdenotter bobdenotter commented Jan 24, 2019

No description provided.

@bobdenotter bobdenotter added this to the Bolt 4 alpha 2 milestone Jan 24, 2019
@bobdenotter bobdenotter self-assigned this Jan 24, 2019
@JarJak
Copy link
Member

@JarJak JarJak commented Jan 24, 2019

The only place where define is used, in fields/_base.html.twig:

{# Set variant #}
{% set variant = define.variant|default('normal') %}

This can be safely replaced with field.definition.variant if there will be a check if field is defined (otherwise all required fields must be set).
Also let's add a comment on the top of this template which variables are required and which are optional.

Loading

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants