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

Clean up NullableField #4114

Merged
merged 1 commit into from Jun 17, 2015
Merged

Clean up NullableField #4114

merged 1 commit into from Jun 17, 2015

Conversation

assertchris
Copy link
Contributor

No description provided.

* @return NullableField
*
* @param FormField $valueField
* @param null $isNullLabel
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

boolean instead of null?

@assertchris
Copy link
Contributor Author

@tractorcow ping

if ( is_null($this->isNullLabel) ) {
// Set a default label if one is not provided.

if($isNullLabel) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need to support false for explicitly empty labels. Can we change this to if(isset($isNullLabel)) to keep the current behaviour?

@assertchris
Copy link
Contributor Author

Fixed

tractorcow pushed a commit that referenced this pull request Jun 17, 2015
@tractorcow tractorcow merged commit 438ee49 into silverstripe:3.1 Jun 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants