public static function FeedImportFilter::removeProperty in Feed Import 8
Same name in this branch
- 8 feed_import_base/filters/feed_import_default_filters.php \FeedImportFilter::removeProperty()
- 8 feed_import_base/src/Filter/FeedImportFilter.php \Drupal\feed_import_base\FeedImportFilter::removeProperty()
Same name and namespace in other branches
- 7.3 feed_import_base/filters/feed_import_default_filters.php \FeedImportFilter::removeProperty()
- 7.2 feed_import_filter.inc.php \FeedImportFilter::removeProperty()
Removes a property
Parameters
mixed $field: The field where to remove
string $property: Property to remove
Return value
mixed Field without property
File
- feed_import_base/
filters/ feed_import_default_filters.php, line 189 - Provides filters for feed import.
Class
- FeedImportFilter
- This class contains default filters for feed import.
Code
public static function removeProperty($field, $property = NULL) {
if ($property) {
if (is_array($field)) {
unset($field[$property]);
}
elseif (is_object($field)) {
unset($field->{$property});
}
}
return $field;
}