aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag
diff options
context:
space:
mode:
Diffstat (limited to 'src/Wallabag')
-rw-r--r--src/Wallabag/ApiBundle/Controller/TagRestController.php2
-rw-r--r--src/Wallabag/CoreBundle/Command/ListUserCommand.php2
-rw-r--r--src/Wallabag/CoreBundle/Command/ShowUserCommand.php2
-rw-r--r--src/Wallabag/CoreBundle/Controller/ConfigController.php2
-rw-r--r--src/Wallabag/CoreBundle/Controller/EntryController.php2
-rw-r--r--src/Wallabag/CoreBundle/Controller/ExportController.php2
-rw-r--r--src/Wallabag/CoreBundle/Controller/TagController.php2
-rw-r--r--src/Wallabag/CoreBundle/Event/Subscriber/TablePrefixSubscriber.php2
-rw-r--r--src/Wallabag/CoreBundle/Form/DataTransformer/StringToListTransformer.php2
-rw-r--r--src/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilder.php4
-rw-r--r--src/Wallabag/CoreBundle/Helper/ContentProxy.php2
-rw-r--r--src/Wallabag/CoreBundle/Operator/Doctrine/Matches.php2
-rw-r--r--src/Wallabag/CoreBundle/Operator/Doctrine/NotMatches.php2
-rw-r--r--src/Wallabag/CoreBundle/Operator/PHP/Matches.php2
-rw-r--r--src/Wallabag/CoreBundle/Operator/PHP/NotMatches.php2
-rw-r--r--src/Wallabag/ImportBundle/Import/AbstractImport.php2
-rw-r--r--src/Wallabag/ImportBundle/Import/BrowserImport.php2
-rw-r--r--src/Wallabag/ImportBundle/Import/ChromeImport.php2
-rw-r--r--src/Wallabag/ImportBundle/Import/FirefoxImport.php2
-rw-r--r--src/Wallabag/ImportBundle/Import/InstapaperImport.php6
-rw-r--r--src/Wallabag/ImportBundle/Import/PocketImport.php12
-rw-r--r--src/Wallabag/ImportBundle/Import/WallabagV1Import.php2
22 files changed, 30 insertions, 30 deletions
diff --git a/src/Wallabag/ApiBundle/Controller/TagRestController.php b/src/Wallabag/ApiBundle/Controller/TagRestController.php
index d19f1228..9d333fe4 100644
--- a/src/Wallabag/ApiBundle/Controller/TagRestController.php
+++ b/src/Wallabag/ApiBundle/Controller/TagRestController.php
@@ -145,7 +145,7 @@ class TagRestController extends WallabagRestController
145 $em = $this->getDoctrine()->getManager(); 145 $em = $this->getDoctrine()->getManager();
146 146
147 foreach ($tags as $tag) { 147 foreach ($tags as $tag) {
148 if (count($tag->getEntries()) === 0) { 148 if (0 === count($tag->getEntries())) {
149 $em->remove($tag); 149 $em->remove($tag);
150 } 150 }
151 } 151 }
diff --git a/src/Wallabag/CoreBundle/Command/ListUserCommand.php b/src/Wallabag/CoreBundle/Command/ListUserCommand.php
index 20660d18..68e515da 100644
--- a/src/Wallabag/CoreBundle/Command/ListUserCommand.php
+++ b/src/Wallabag/CoreBundle/Command/ListUserCommand.php
@@ -52,7 +52,7 @@ class ListUserCommand extends ContainerAwareCommand
52 '%s/%s%s user(s) displayed.', 52 '%s/%s%s user(s) displayed.',
53 count($users), 53 count($users),
54 $nbUsers, 54 $nbUsers,
55 $input->getArgument('search') === null ? '' : ' (filtered)' 55 null === $input->getArgument('search') ? '' : ' (filtered)'
56 ) 56 )
57 ); 57 );
58 58
diff --git a/src/Wallabag/CoreBundle/Command/ShowUserCommand.php b/src/Wallabag/CoreBundle/Command/ShowUserCommand.php
index 2dca32c4..a0184267 100644
--- a/src/Wallabag/CoreBundle/Command/ShowUserCommand.php
+++ b/src/Wallabag/CoreBundle/Command/ShowUserCommand.php
@@ -56,7 +56,7 @@ class ShowUserCommand extends ContainerAwareCommand
56 sprintf('Email: %s', $user->getEmail()), 56 sprintf('Email: %s', $user->getEmail()),
57 sprintf('Display name: %s', $user->getName()), 57 sprintf('Display name: %s', $user->getName()),
58 sprintf('Creation date: %s', $user->getCreatedAt()->format('Y-m-d H:i:s')), 58 sprintf('Creation date: %s', $user->getCreatedAt()->format('Y-m-d H:i:s')),
59 sprintf('Last login: %s', $user->getLastLogin() !== null ? $user->getLastLogin()->format('Y-m-d H:i:s') : 'never'), 59 sprintf('Last login: %s', null !== $user->getLastLogin() ? $user->getLastLogin()->format('Y-m-d H:i:s') : 'never'),
60 sprintf('2FA activated: %s', $user->isTwoFactorAuthentication() ? 'yes' : 'no'), 60 sprintf('2FA activated: %s', $user->isTwoFactorAuthentication() ? 'yes' : 'no'),
61 ]); 61 ]);
62 } 62 }
diff --git a/src/Wallabag/CoreBundle/Controller/ConfigController.php b/src/Wallabag/CoreBundle/Controller/ConfigController.php
index 7e39992d..a89bb780 100644
--- a/src/Wallabag/CoreBundle/Controller/ConfigController.php
+++ b/src/Wallabag/CoreBundle/Controller/ConfigController.php
@@ -348,7 +348,7 @@ class ConfigController extends Controller
348 $em = $this->getDoctrine()->getManager(); 348 $em = $this->getDoctrine()->getManager();
349 349
350 foreach ($tags as $tag) { 350 foreach ($tags as $tag) {
351 if (count($tag->getEntries()) === 0) { 351 if (0 === count($tag->getEntries())) {
352 $em->remove($tag); 352 $em->remove($tag);
353 } 353 }
354 } 354 }
diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php
index b0b74c38..840dc254 100644
--- a/src/Wallabag/CoreBundle/Controller/EntryController.php
+++ b/src/Wallabag/CoreBundle/Controller/EntryController.php
@@ -195,7 +195,7 @@ class EntryController extends Controller
195 public function showUnreadAction(Request $request, $page) 195 public function showUnreadAction(Request $request, $page)
196 { 196 {
197 // load the quickstart if no entry in database 197 // load the quickstart if no entry in database
198 if ((int) $page === 1 && $this->get('wallabag_core.entry_repository')->countAllEntriesByUser($this->getUser()->getId()) === 0) { 198 if (1 === (int) $page && 0 === $this->get('wallabag_core.entry_repository')->countAllEntriesByUser($this->getUser()->getId())) {
199 return $this->redirect($this->generateUrl('quickstart')); 199 return $this->redirect($this->generateUrl('quickstart'));
200 } 200 }
201 201
diff --git a/src/Wallabag/CoreBundle/Controller/ExportController.php b/src/Wallabag/CoreBundle/Controller/ExportController.php
index 35a22046..7ca89239 100644
--- a/src/Wallabag/CoreBundle/Controller/ExportController.php
+++ b/src/Wallabag/CoreBundle/Controller/ExportController.php
@@ -59,7 +59,7 @@ class ExportController extends Controller
59 $methodBuilder = 'getBuilderFor' . $method . 'ByUser'; 59 $methodBuilder = 'getBuilderFor' . $method . 'ByUser';
60 $repository = $this->get('wallabag_core.entry_repository'); 60 $repository = $this->get('wallabag_core.entry_repository');
61 61
62 if ($category === 'tag_entries') { 62 if ('tag_entries' === $category) {
63 $tag = $this->get('wallabag_core.tag_repository')->findOneBySlug($request->query->get('tag')); 63 $tag = $this->get('wallabag_core.tag_repository')->findOneBySlug($request->query->get('tag'));
64 64
65 $entries = $repository->findAllByTagId( 65 $entries = $repository->findAllByTagId(
diff --git a/src/Wallabag/CoreBundle/Controller/TagController.php b/src/Wallabag/CoreBundle/Controller/TagController.php
index be2dff98..616c37f2 100644
--- a/src/Wallabag/CoreBundle/Controller/TagController.php
+++ b/src/Wallabag/CoreBundle/Controller/TagController.php
@@ -65,7 +65,7 @@ class TagController extends Controller
65 $em->flush(); 65 $em->flush();
66 66
67 // remove orphan tag in case no entries are associated to it 67 // remove orphan tag in case no entries are associated to it
68 if (count($tag->getEntries()) === 0) { 68 if (0 === count($tag->getEntries())) {
69 $em->remove($tag); 69 $em->remove($tag);
70 $em->flush(); 70 $em->flush();
71 } 71 }
diff --git a/src/Wallabag/CoreBundle/Event/Subscriber/TablePrefixSubscriber.php b/src/Wallabag/CoreBundle/Event/Subscriber/TablePrefixSubscriber.php
index 35902654..fb8f225f 100644
--- a/src/Wallabag/CoreBundle/Event/Subscriber/TablePrefixSubscriber.php
+++ b/src/Wallabag/CoreBundle/Event/Subscriber/TablePrefixSubscriber.php
@@ -42,7 +42,7 @@ class TablePrefixSubscriber implements EventSubscriber
42 $classMetadata->setPrimaryTable(['name' => $this->prefix . $classMetadata->getTableName()]); 42 $classMetadata->setPrimaryTable(['name' => $this->prefix . $classMetadata->getTableName()]);
43 43
44 foreach ($classMetadata->getAssociationMappings() as $fieldName => $mapping) { 44 foreach ($classMetadata->getAssociationMappings() as $fieldName => $mapping) {
45 if ($mapping['type'] === ClassMetadataInfo::MANY_TO_MANY && isset($classMetadata->associationMappings[$fieldName]['joinTable']['name'])) { 45 if (ClassMetadataInfo::MANY_TO_MANY === $mapping['type'] && isset($classMetadata->associationMappings[$fieldName]['joinTable']['name'])) {
46 $mappedTableName = $classMetadata->associationMappings[$fieldName]['joinTable']['name']; 46 $mappedTableName = $classMetadata->associationMappings[$fieldName]['joinTable']['name'];
47 $classMetadata->associationMappings[$fieldName]['joinTable']['name'] = $this->prefix . $mappedTableName; 47 $classMetadata->associationMappings[$fieldName]['joinTable']['name'] = $this->prefix . $mappedTableName;
48 } 48 }
diff --git a/src/Wallabag/CoreBundle/Form/DataTransformer/StringToListTransformer.php b/src/Wallabag/CoreBundle/Form/DataTransformer/StringToListTransformer.php
index cb4bee83..57dbc95e 100644
--- a/src/Wallabag/CoreBundle/Form/DataTransformer/StringToListTransformer.php
+++ b/src/Wallabag/CoreBundle/Form/DataTransformer/StringToListTransformer.php
@@ -48,7 +48,7 @@ class StringToListTransformer implements DataTransformerInterface
48 */ 48 */
49 public function reverseTransform($string) 49 public function reverseTransform($string)
50 { 50 {
51 if ($string === null) { 51 if (null === $string) {
52 return; 52 return;
53 } 53 }
54 54
diff --git a/src/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilder.php b/src/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilder.php
index da19fe31..2c85da62 100644
--- a/src/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilder.php
+++ b/src/Wallabag/CoreBundle/GuzzleSiteAuthenticator/GrabySiteConfigBuilder.php
@@ -58,7 +58,7 @@ class GrabySiteConfigBuilder implements SiteConfigBuilder
58 { 58 {
59 // required by credentials below 59 // required by credentials below
60 $host = strtolower($host); 60 $host = strtolower($host);
61 if (substr($host, 0, 4) === 'www.') { 61 if ('www.' === substr($host, 0, 4)) {
62 $host = substr($host, 4); 62 $host = substr($host, 4);
63 } 63 }
64 64
@@ -113,7 +113,7 @@ class GrabySiteConfigBuilder implements SiteConfigBuilder
113 113
114 $extraFields = []; 114 $extraFields = [];
115 foreach ($extraFieldsStrings as $extraField) { 115 foreach ($extraFieldsStrings as $extraField) {
116 if (strpos($extraField, '=') === false) { 116 if (false === strpos($extraField, '=')) {
117 continue; 117 continue;
118 } 118 }
119 119
diff --git a/src/Wallabag/CoreBundle/Helper/ContentProxy.php b/src/Wallabag/CoreBundle/Helper/ContentProxy.php
index 1ac7ad83..854acb6a 100644
--- a/src/Wallabag/CoreBundle/Helper/ContentProxy.php
+++ b/src/Wallabag/CoreBundle/Helper/ContentProxy.php
@@ -125,7 +125,7 @@ class ContentProxy
125 $date = $value; 125 $date = $value;
126 126
127 // is it a timestamp? 127 // is it a timestamp?
128 if (filter_var($date, FILTER_VALIDATE_INT) !== false) { 128 if (false !== filter_var($date, FILTER_VALIDATE_INT)) {
129 $date = '@' . $date; 129 $date = '@' . $date;
130 } 130 }
131 131
diff --git a/src/Wallabag/CoreBundle/Operator/Doctrine/Matches.php b/src/Wallabag/CoreBundle/Operator/Doctrine/Matches.php
index e6bb03b1..e1610161 100644
--- a/src/Wallabag/CoreBundle/Operator/Doctrine/Matches.php
+++ b/src/Wallabag/CoreBundle/Operator/Doctrine/Matches.php
@@ -16,7 +16,7 @@ class Matches
16{ 16{
17 public function __invoke($subject, $pattern) 17 public function __invoke($subject, $pattern)
18 { 18 {
19 if ($pattern[0] === "'") { 19 if ("'" === $pattern[0]) {
20 $pattern = sprintf("'%%%s%%'", substr($pattern, 1, -1)); 20 $pattern = sprintf("'%%%s%%'", substr($pattern, 1, -1));
21 } 21 }
22 22
diff --git a/src/Wallabag/CoreBundle/Operator/Doctrine/NotMatches.php b/src/Wallabag/CoreBundle/Operator/Doctrine/NotMatches.php
index b7f9da57..8e50f8d6 100644
--- a/src/Wallabag/CoreBundle/Operator/Doctrine/NotMatches.php
+++ b/src/Wallabag/CoreBundle/Operator/Doctrine/NotMatches.php
@@ -16,7 +16,7 @@ class NotMatches
16{ 16{
17 public function __invoke($subject, $pattern) 17 public function __invoke($subject, $pattern)
18 { 18 {
19 if ($pattern[0] === "'") { 19 if ("'" === $pattern[0]) {
20 $pattern = sprintf("'%%%s%%'", substr($pattern, 1, -1)); 20 $pattern = sprintf("'%%%s%%'", substr($pattern, 1, -1));
21 } 21 }
22 22
diff --git a/src/Wallabag/CoreBundle/Operator/PHP/Matches.php b/src/Wallabag/CoreBundle/Operator/PHP/Matches.php
index 987ed2a5..bc0c3f8f 100644
--- a/src/Wallabag/CoreBundle/Operator/PHP/Matches.php
+++ b/src/Wallabag/CoreBundle/Operator/PHP/Matches.php
@@ -16,6 +16,6 @@ class Matches
16{ 16{
17 public function __invoke($subject, $pattern) 17 public function __invoke($subject, $pattern)
18 { 18 {
19 return stripos($subject, $pattern) !== false; 19 return false !== stripos($subject, $pattern);
20 } 20 }
21} 21}
diff --git a/src/Wallabag/CoreBundle/Operator/PHP/NotMatches.php b/src/Wallabag/CoreBundle/Operator/PHP/NotMatches.php
index 68b2676f..bd4d887a 100644
--- a/src/Wallabag/CoreBundle/Operator/PHP/NotMatches.php
+++ b/src/Wallabag/CoreBundle/Operator/PHP/NotMatches.php
@@ -16,6 +16,6 @@ class NotMatches
16{ 16{
17 public function __invoke($subject, $pattern) 17 public function __invoke($subject, $pattern)
18 { 18 {
19 return stripos($subject, $pattern) === false; 19 return false === stripos($subject, $pattern);
20 } 20 }
21} 21}
diff --git a/src/Wallabag/ImportBundle/Import/AbstractImport.php b/src/Wallabag/ImportBundle/Import/AbstractImport.php
index cb46db09..58a234f4 100644
--- a/src/Wallabag/ImportBundle/Import/AbstractImport.php
+++ b/src/Wallabag/ImportBundle/Import/AbstractImport.php
@@ -165,7 +165,7 @@ abstract class AbstractImport implements ImportInterface
165 $entryToBeFlushed[] = $entry; 165 $entryToBeFlushed[] = $entry;
166 166
167 // flush every 20 entries 167 // flush every 20 entries
168 if (($i % 20) === 0) { 168 if (0 === ($i % 20)) {
169 $this->em->flush(); 169 $this->em->flush();
170 170
171 foreach ($entryToBeFlushed as $entry) { 171 foreach ($entryToBeFlushed as $entry) {
diff --git a/src/Wallabag/ImportBundle/Import/BrowserImport.php b/src/Wallabag/ImportBundle/Import/BrowserImport.php
index 78077324..b5593180 100644
--- a/src/Wallabag/ImportBundle/Import/BrowserImport.php
+++ b/src/Wallabag/ImportBundle/Import/BrowserImport.php
@@ -171,7 +171,7 @@ abstract class BrowserImport extends AbstractImport
171 $entryToBeFlushed[] = $entry; 171 $entryToBeFlushed[] = $entry;
172 172
173 // flush every 20 entries 173 // flush every 20 entries
174 if (($i % 20) === 0) { 174 if (0 === ($i % 20)) {
175 $this->em->flush(); 175 $this->em->flush();
176 176
177 foreach ($entryToBeFlushed as $entry) { 177 foreach ($entryToBeFlushed as $entry) {
diff --git a/src/Wallabag/ImportBundle/Import/ChromeImport.php b/src/Wallabag/ImportBundle/Import/ChromeImport.php
index e3ba636a..09183abe 100644
--- a/src/Wallabag/ImportBundle/Import/ChromeImport.php
+++ b/src/Wallabag/ImportBundle/Import/ChromeImport.php
@@ -45,7 +45,7 @@ class ChromeImport extends BrowserImport
45 'created_at' => substr($entry['date_added'], 0, 10), 45 'created_at' => substr($entry['date_added'], 0, 10),
46 ]; 46 ];
47 47
48 if (array_key_exists('tags', $entry) && $entry['tags'] !== '') { 48 if (array_key_exists('tags', $entry) && '' !== $entry['tags']) {
49 $data['tags'] = $entry['tags']; 49 $data['tags'] = $entry['tags'];
50 } 50 }
51 51
diff --git a/src/Wallabag/ImportBundle/Import/FirefoxImport.php b/src/Wallabag/ImportBundle/Import/FirefoxImport.php
index c18e7e93..73269fe1 100644
--- a/src/Wallabag/ImportBundle/Import/FirefoxImport.php
+++ b/src/Wallabag/ImportBundle/Import/FirefoxImport.php
@@ -45,7 +45,7 @@ class FirefoxImport extends BrowserImport
45 'created_at' => substr($entry['dateAdded'], 0, 10), 45 'created_at' => substr($entry['dateAdded'], 0, 10),
46 ]; 46 ];
47 47
48 if (array_key_exists('tags', $entry) && $entry['tags'] !== '') { 48 if (array_key_exists('tags', $entry) && '' !== $entry['tags']) {
49 $data['tags'] = $entry['tags']; 49 $data['tags'] = $entry['tags'];
50 } 50 }
51 51
diff --git a/src/Wallabag/ImportBundle/Import/InstapaperImport.php b/src/Wallabag/ImportBundle/Import/InstapaperImport.php
index 7d70154a..7ab69e7a 100644
--- a/src/Wallabag/ImportBundle/Import/InstapaperImport.php
+++ b/src/Wallabag/ImportBundle/Import/InstapaperImport.php
@@ -63,7 +63,7 @@ class InstapaperImport extends AbstractImport
63 63
64 $entries = []; 64 $entries = [];
65 $handle = fopen($this->filepath, 'r'); 65 $handle = fopen($this->filepath, 'r');
66 while (($data = fgetcsv($handle, 10240)) !== false) { 66 while (false !== ($data = fgetcsv($handle, 10240))) {
67 if ('URL' === $data[0]) { 67 if ('URL' === $data[0]) {
68 continue; 68 continue;
69 } 69 }
@@ -80,8 +80,8 @@ class InstapaperImport extends AbstractImport
80 'url' => $data[0], 80 'url' => $data[0],
81 'title' => $data[1], 81 'title' => $data[1],
82 'status' => $data[3], 82 'status' => $data[3],
83 'is_archived' => $data[3] === 'Archive' || $data[3] === 'Starred', 83 'is_archived' => 'Archive' === $data[3] || 'Starred' === $data[3],
84 'is_starred' => $data[3] === 'Starred', 84 'is_starred' => 'Starred' === $data[3],
85 'html' => false, 85 'html' => false,
86 'tags' => $tags, 86 'tags' => $tags,
87 ]; 87 ];
diff --git a/src/Wallabag/ImportBundle/Import/PocketImport.php b/src/Wallabag/ImportBundle/Import/PocketImport.php
index 7d38826b..dddb87f4 100644
--- a/src/Wallabag/ImportBundle/Import/PocketImport.php
+++ b/src/Wallabag/ImportBundle/Import/PocketImport.php
@@ -149,7 +149,7 @@ class PocketImport extends AbstractImport
149 // - first call get 5k offset 0 149 // - first call get 5k offset 0
150 // - second call get 5k offset 5k 150 // - second call get 5k offset 5k
151 // - and so on 151 // - and so on
152 if (count($entries['list']) === self::NB_ELEMENTS) { 152 if (self::NB_ELEMENTS === count($entries['list'])) {
153 ++$run; 153 ++$run;
154 154
155 return $this->import(self::NB_ELEMENTS * $run); 155 return $this->import(self::NB_ELEMENTS * $run);
@@ -175,7 +175,7 @@ class PocketImport extends AbstractImport
175 */ 175 */
176 public function parseEntry(array $importedEntry) 176 public function parseEntry(array $importedEntry)
177 { 177 {
178 $url = isset($importedEntry['resolved_url']) && $importedEntry['resolved_url'] !== '' ? $importedEntry['resolved_url'] : $importedEntry['given_url']; 178 $url = isset($importedEntry['resolved_url']) && '' !== $importedEntry['resolved_url'] ? $importedEntry['resolved_url'] : $importedEntry['given_url'];
179 179
180 $existingEntry = $this->em 180 $existingEntry = $this->em
181 ->getRepository('WallabagCoreBundle:Entry') 181 ->getRepository('WallabagCoreBundle:Entry')
@@ -194,15 +194,15 @@ class PocketImport extends AbstractImport
194 $this->fetchContent($entry, $url); 194 $this->fetchContent($entry, $url);
195 195
196 // 0, 1, 2 - 1 if the item is archived - 2 if the item should be deleted 196 // 0, 1, 2 - 1 if the item is archived - 2 if the item should be deleted
197 $entry->setArchived($importedEntry['status'] === 1 || $this->markAsRead); 197 $entry->setArchived(1 === $importedEntry['status'] || $this->markAsRead);
198 198
199 // 0 or 1 - 1 If the item is starred 199 // 0 or 1 - 1 If the item is starred
200 $entry->setStarred($importedEntry['favorite'] === 1); 200 $entry->setStarred(1 === $importedEntry['favorite']);
201 201
202 $title = 'Untitled'; 202 $title = 'Untitled';
203 if (isset($importedEntry['resolved_title']) && $importedEntry['resolved_title'] !== '') { 203 if (isset($importedEntry['resolved_title']) && '' !== $importedEntry['resolved_title']) {
204 $title = $importedEntry['resolved_title']; 204 $title = $importedEntry['resolved_title'];
205 } elseif (isset($importedEntry['given_title']) && $importedEntry['given_title'] !== '') { 205 } elseif (isset($importedEntry['given_title']) && '' !== $importedEntry['given_title']) {
206 $title = $importedEntry['given_title']; 206 $title = $importedEntry['given_title'];
207 } 207 }
208 208
diff --git a/src/Wallabag/ImportBundle/Import/WallabagV1Import.php b/src/Wallabag/ImportBundle/Import/WallabagV1Import.php
index d585d44d..a35c411e 100644
--- a/src/Wallabag/ImportBundle/Import/WallabagV1Import.php
+++ b/src/Wallabag/ImportBundle/Import/WallabagV1Import.php
@@ -61,7 +61,7 @@ class WallabagV1Import extends WallabagImport
61 $data['html'] = $this->fetchingErrorMessage; 61 $data['html'] = $this->fetchingErrorMessage;
62 } 62 }
63 63
64 if (array_key_exists('tags', $entry) && $entry['tags'] !== '') { 64 if (array_key_exists('tags', $entry) && '' !== $entry['tags']) {
65 $data['tags'] = $entry['tags']; 65 $data['tags'] = $entry['tags'];
66 } 66 }
67 67