Skip to content
Permalink
Browse files

Use new $table->entityClass() instead of $table->newEntity()

  • Loading branch information...
robertpustulka committed Jul 2, 2015
1 parent 314cb7d commit fc66850c926504d90cb87389bf0e4d665242ec4c
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/ORM/Behavior/TranslateBehavior.php
@@ -444,11 +444,11 @@ public function groupTranslations($results)
$result = [];
foreach ($grouped->combine('field', 'content', 'locale') as $locale => $keys) {
$translation = $this->_table->newEntity($keys + ['locale' => $locale], [
$entityClass = $this->_table->entityClass();
$translation = new $entityClass($keys + ['locale' => $locale], [
'markNew' => false,
'useSetters' => false,
'markClean' => true,
'validate' => false
'markClean' => true
]);
$result[$locale] = $translation;
}

0 comments on commit fc66850

Please sign in to comment.
You can’t perform that action at this time.