]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
CS
authorThomas Citharel <tcit@tcit.fr>
Thu, 11 Feb 2016 12:39:21 +0000 (13:39 +0100)
committerThomas Citharel <tcit@tcit.fr>
Thu, 11 Feb 2016 12:39:21 +0000 (13:39 +0100)
src/Wallabag/ImportBundle/Import/WallabagV1Import.php
src/Wallabag/ImportBundle/Tests/Import/WallabagV1ImportTest.php
src/Wallabag/ImportBundle/Tests/Import/WallabagV2ImportTest.php

index 82b52ad3f02fc765e03aae7f8663000f4e080ee2..02327312515fcc4a58f38d2f10c1f0f8b9137f45 100644 (file)
@@ -10,7 +10,6 @@ use Wallabag\UserBundle\Entity\User;
 use Wallabag\CoreBundle\Tools\Utils;
 use Wallabag\CoreBundle\Helper\ContentProxy;
 
-
 class WallabagV1Import implements ImportInterface
 {
     protected $user;
@@ -127,10 +126,10 @@ class WallabagV1Import implements ImportInterface
     protected function parseEntries($entries)
     {
         $i = 1;
-        /**
+        /*
          * Untitled in all languages from v1. This should never have been translated
          */
-        $untitled = array('Untitled','Sans titre','podle nadpisu','Sin título','با عنوان','per titolo','Sem título','Без названия','po naslovu','Без назви');
+        $untitled = array('Untitled', 'Sans titre', 'podle nadpisu', 'Sin título', 'با عنوان', 'per titolo', 'Sem título', 'Без названия', 'po naslovu', 'Без назви');
 
         foreach ($entries as $importedEntry) {
             $existingEntry = $this->em
@@ -145,7 +144,7 @@ class WallabagV1Import implements ImportInterface
             // @see ContentProxy->updateEntry
             $entry = new Entry($this->user);
             $entry->setUrl($importedEntry['url']);
-            if (in_array($importedEntry['title'],$untitled)) {
+            if (in_array($importedEntry['title'], $untitled)) {
                 $entry = $this->contentProxy->updateEntry($entry, $entry->getUrl());
             } else {
                 $entry->setContent($importedEntry['content']);
index 78cc19b6bcbc7fc542617448050277fdee7a839f..093420f92a689267952823c509738d225de3c6fd 100644 (file)
@@ -14,7 +14,6 @@ class WallabagV1ImportTest extends \PHPUnit_Framework_TestCase
     protected $logHandler;
     protected $contentProxy;
 
-
     private function getWallabagV1Import($unsetUser = false)
     {
         $this->user = new User();
@@ -27,7 +26,7 @@ class WallabagV1ImportTest extends \PHPUnit_Framework_TestCase
             ->disableOriginalConstructor()
             ->getMock();
 
-        $wallabag = new WallabagV1Import($this->em,$this->contentProxy);
+        $wallabag = new WallabagV1Import($this->em, $this->contentProxy);
 
         $this->logHandler = new TestHandler();
         $logger = new Logger('test', array($this->logHandler));
index 0b33afb61383dc7f554fc597fe17ede4dc1bb4a8..ebabb8f75919308c7c557f8ba289a20c4477cb11 100644 (file)
@@ -26,7 +26,7 @@ class WallabagV2ImportTest extends \PHPUnit_Framework_TestCase
             ->disableOriginalConstructor()
             ->getMock();
 
-        $wallabag = new WallabagV2Import($this->em,$this->contentProxy);
+        $wallabag = new WallabagV2Import($this->em, $this->contentProxy);
 
         $this->logHandler = new TestHandler();
         $logger = new Logger('test', array($this->logHandler));