/** * Get the count of presence of contract's metadata * * @return array */ public function getMetadataQuality() { $metadata = []; $metadataSchema = config('metadata.schema.metadata'); unset($metadataSchema['file_size'], $metadataSchema['company'], $metadataSchema['concession']); foreach ($metadataSchema as $key => $value) { $count = $this->contract->getMetadataQuality($key); $metadata[$key] = $count; } return $metadata; }