/**
  * Localize the changeset values
  *
  * @param array $changeset
  *
  * @return array
  */
 protected function convertChangeset(array $changeset)
 {
     $formats = $this->localeResolver->getFormats();
     foreach ($changeset as $attribute => $changes) {
         $attributeName = $attribute;
         if (preg_match('/^(?<attribute>[a-zA-Z0-9_]+)-.+$/', $attribute, $matches)) {
             $attributeName = $matches['attribute'];
         }
         foreach ($changes as $key => $value) {
             $changeset[$attribute][$key] = $this->converter->convertDefaultToLocalizedValue($attributeName, $value, $formats);
         }
     }
     return $changeset;
 }