RealisticDummyContentValueField.php in Realistic Dummy Content 3.x
File
api/src/includes/RealisticDummyContentValueField.php
View source
<?php
namespace Drupal\realistic_dummy_content_api\includes;
use Drupal\realistic_dummy_content_api\Framework\Framework;
class RealisticDummyContentValueField extends RealisticDummyContentField {
public function implementValueFromFile($file) : array {
$value = $file
->value();
if ($value === NULL) {
return [];
}
return $this
->format($value);
}
public function format($value) : array {
return Framework::instance()
->formatProperty('value', $value);
}
}