function CacheableNormalization::omitIfEmpty
Converts the object to a CacheableOmission if the normalization is empty.
Return value
self|\Drupal\jsonapi\Normalizer\Value\CacheableOmission A CacheableOmission if the normalization is considered empty, self otherwise.
File
- 
              core/modules/ jsonapi/ src/ Normalizer/ Value/ CacheableNormalization.php, line 76 
Class
- CacheableNormalization
- Use to store normalized data and its cacheability.
Namespace
Drupal\jsonapi\Normalizer\ValueCode
public function omitIfEmpty() {
  return empty($this->normalization) ? new CacheableOmission($this) : $this;
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
