3 namespace Wallabag\ImportBundle\Import
;
5 class WallabagV1Import
extends WallabagImport
10 public function getName()
18 public function getUrl()
20 return 'import_wallabag_v1';
26 public function getDescription()
28 return 'import.wallabag_v1.description';
34 protected function prepareEntry($entry = [])
37 'title' => $entry['title'],
38 'html' => $entry['content'],
39 'url' => $entry['url'],
42 'is_archived' => $entry['is_read'] || $this->markAsRead
,
43 'is_starred' => $entry['is_fav'],
48 // force content to be refreshed in case on bad fetch in the v1 installation
49 if (in_array($entry['title'], $this->untitled
)) {
54 if (array_key_exists('tags', $entry) && $entry['tags'] != '') {
55 $data['tags'] = $entry['tags'];
64 protected function setEntryAsRead(array $importedEntry)
66 $importedEntry['is_read'] = 1;
68 return $importedEntry;