Merge pull request #2688 from wallabag/fix-browsers-import

Fixed imports with is_starred and is_archived
This commit is contained in:
Nicolas Lœuillet 2016-12-08 09:07:09 +01:00 committed by GitHub
commit 75ae3c8d82
3 changed files with 6 additions and 3 deletions

View File

@ -39,7 +39,8 @@ class ChromeImport extends BrowserImport
'title' => $entry['name'],
'html' => false,
'url' => $entry['url'],
'is_archived' => $this->markAsRead,
'is_archived' => (int) $this->markAsRead,
'is_starred' => false,
'tags' => '',
'created_at' => substr($entry['date_added'], 0, 10),
];

View File

@ -39,7 +39,8 @@ class FirefoxImport extends BrowserImport
'title' => $entry['title'],
'html' => false,
'url' => $entry['uri'],
'is_archived' => $this->markAsRead,
'is_archived' => (int) $this->markAsRead,
'is_starred' => false,
'tags' => '',
'created_at' => substr($entry['dateAdded'], 0, 10),
];

View File

@ -36,7 +36,8 @@ class WallabagV2Import extends WallabagImport
return [
'html' => $entry['content'],
'content_type' => $entry['mimetype'],
'is_archived' => ($entry['is_archived'] || $this->markAsRead),
'is_archived' => (int) ($entry['is_archived'] || $this->markAsRead),
'is_starred' => false,
] + $entry;
}