aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/Wallabag/ImportBundle/Import/InstapaperImport.php
diff options
context:
space:
mode:
authorJérémy Benoist <j0k3r@users.noreply.github.com>2019-01-04 11:06:53 +0100
committerGitHub <noreply@github.com>2019-01-04 11:06:53 +0100
commit8f5c4b083ccf354e7942b4f50626de945d29aad7 (patch)
tree7b10762300382a803c711c465eea42d2c2f2b80b /src/Wallabag/ImportBundle/Import/InstapaperImport.php
parent2378fd6347dd1a824c8e1f4f7c3892c6eccddc85 (diff)
parent9f8f188d928b47503d39348c5990379a572b570a (diff)
downloadwallabag-8f5c4b083ccf354e7942b4f50626de945d29aad7.tar.gz
wallabag-8f5c4b083ccf354e7942b4f50626de945d29aad7.tar.zst
wallabag-8f5c4b083ccf354e7942b4f50626de945d29aad7.zip
Merge pull request #3816 from wallabag/validate-import-entry
Validate imported entry to avoid error on import
Diffstat (limited to 'src/Wallabag/ImportBundle/Import/InstapaperImport.php')
-rw-r--r--src/Wallabag/ImportBundle/Import/InstapaperImport.php12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/Wallabag/ImportBundle/Import/InstapaperImport.php b/src/Wallabag/ImportBundle/Import/InstapaperImport.php
index e4f0970c..5a18c7c0 100644
--- a/src/Wallabag/ImportBundle/Import/InstapaperImport.php
+++ b/src/Wallabag/ImportBundle/Import/InstapaperImport.php
@@ -108,6 +108,18 @@ class InstapaperImport extends AbstractImport
108 /** 108 /**
109 * {@inheritdoc} 109 * {@inheritdoc}
110 */ 110 */
111 public function validateEntry(array $importedEntry)
112 {
113 if (empty($importedEntry['url'])) {
114 return false;
115 }
116
117 return true;
118 }
119
120 /**
121 * {@inheritdoc}
122 */
111 public function parseEntry(array $importedEntry) 123 public function parseEntry(array $importedEntry)
112 { 124 {
113 $existingEntry = $this->em 125 $existingEntry = $this->em