diff options
author | Paulino Michelazzo <paulino@michelazzo.com.br> | 2016-10-18 22:48:23 +0200 |
---|---|---|
committer | Paulino Michelazzo <paulino@michelazzo.com.br> | 2016-10-18 22:48:23 +0200 |
commit | 99731f0bb1f6fd2815eeb9af504ce86df927657b (patch) | |
tree | b080efc608d2bbd52b77a4a0067402007f50c5a8 /src/Wallabag/ImportBundle/Import/WallabagV2Import.php | |
parent | 3a3c6b866b52721431bed22426d9abfcd0d2dfe0 (diff) | |
parent | 7180aaed45dce62e40620a9e4b202526ebd6a3bb (diff) | |
download | wallabag-99731f0bb1f6fd2815eeb9af504ce86df927657b.tar.gz wallabag-99731f0bb1f6fd2815eeb9af504ce86df927657b.tar.zst wallabag-99731f0bb1f6fd2815eeb9af504ce86df927657b.zip |
Merge remote-tracking branch 'wallabag/master'
Diffstat (limited to 'src/Wallabag/ImportBundle/Import/WallabagV2Import.php')
-rw-r--r-- | src/Wallabag/ImportBundle/Import/WallabagV2Import.php | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/Wallabag/ImportBundle/Import/WallabagV2Import.php b/src/Wallabag/ImportBundle/Import/WallabagV2Import.php index d0035b63..37c8ca14 100644 --- a/src/Wallabag/ImportBundle/Import/WallabagV2Import.php +++ b/src/Wallabag/ImportBundle/Import/WallabagV2Import.php | |||
@@ -31,12 +31,22 @@ class WallabagV2Import extends WallabagImport | |||
31 | /** | 31 | /** |
32 | * {@inheritdoc} | 32 | * {@inheritdoc} |
33 | */ | 33 | */ |
34 | protected function prepareEntry($entry = [], $markAsRead = false) | 34 | protected function prepareEntry($entry = []) |
35 | { | 35 | { |
36 | return [ | 36 | return [ |
37 | 'html' => $entry['content'], | 37 | 'html' => $entry['content'], |
38 | 'content_type' => $entry['mimetype'], | 38 | 'content_type' => $entry['mimetype'], |
39 | 'is_archived' => ($entry['is_archived'] || $markAsRead), | 39 | 'is_archived' => ($entry['is_archived'] || $this->markAsRead), |
40 | ] + $entry; | 40 | ] + $entry; |
41 | } | 41 | } |
42 | |||
43 | /** | ||
44 | * {@inheritdoc} | ||
45 | */ | ||
46 | protected function setEntryAsRead(array $importedEntry) | ||
47 | { | ||
48 | $importedEntry['is_archived'] = 1; | ||
49 | |||
50 | return $importedEntry; | ||
51 | } | ||
42 | } | 52 | } |