소스 검색

[docs] applied fix from @stfalcon

gediminasm 14 년 전
부모
커밋
415a9de08d
1개의 변경된 파일2개의 추가작업 그리고 3개의 파일을 삭제
  1. 2 3
      doc/translatable.md

+ 2 - 3
doc/translatable.md

@@ -358,14 +358,13 @@ the slug, so the value as an additional translation should be processed when cre
 ### Example of multiple translations:
 
     // persisting multiple translations, assume default locale is EN
-    $repo = $em->getRepository('Gedmo\\Translatable\\Entity\\Translation');
+    $repository = $em->getRepository('Gedmo\\Translatable\\Entity\\Translation');
     // it works for ODM also
     $article = new Article;
     $article->setTitle('My article en');
     $article->setContent('content en');
 
-    $repo
-        ->translate($article, 'title', 'de', 'my article de')
+    $repository->translate($article, 'title', 'de', 'my article de')
         ->translate($article, 'content', 'de', 'content de')
         ->translate($article, 'title', 'ru', 'my article ru')
         ->translate($article, 'content', 'ru', 'content ru');