You are here

public function EntityListWrapper::validate in Entity API 7

Overridden.

Overrides EntityMetadataWrapper::validate

File

includes/entity.wrapper.inc, line 1159
Provides wrappers allowing easy usage of the entity metadata.

Class

EntityListWrapper
Wraps a list of values.

Code

public function validate($value) {

  // Required lists may not be empty or unset.
  if (!empty($this->info['required']) && empty($value)) {
    return FALSE;
  }
  return parent::validate($value);
}