Skip to content

Commit

Permalink
update the filter value to use is:reading of the Continue Reading filter
Browse files Browse the repository at this point in the history
  • Loading branch information
sywhb committed Oct 10, 2023
1 parent 29c8786 commit 768845e
Show file tree
Hide file tree
Showing 4 changed files with 27 additions and 2 deletions.
5 changes: 4 additions & 1 deletion packages/api/src/services/create_user.ts
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,10 @@ const createDefaultFiltersForUser =
async (userId: string): Promise<Filter[]> => {
const defaultFilters = [
{ name: 'Inbox', filter: 'in:inbox' },
{ name: 'Continue Reading', filter: 'in:inbox sort:read-desc is:unread' },
{
name: 'Continue Reading',
filter: 'in:inbox sort:read-desc is:reading',
},
{ name: 'Non-Feed Items', filter: 'in:library' },
{ name: 'Highlights', filter: 'has:highlights mode:highlights' },
{ name: 'Unlabeled', filter: 'no:label' },
Expand Down
11 changes: 11 additions & 0 deletions packages/db/migrations/0130.do.update_continue_reading_filter.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
-- Type: DO
-- Name: update_continue_reading_filter
-- Description: Update the filter value in the Continue Reading filter

BEGIN;

UPDATE omnivore.filters
SET filter = 'in:inbox sort:read-desc is:reading'
WHERE name = 'Continue Reading' AND default_filter = true;

COMMIT;
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
-- Type: UNDO
-- Name: update_continue_reading_filter
-- Description: Update the filter value in the Continue Reading filter

BEGIN;

UPDATE omnivore.filters
SET filter = 'in:inbox sort:read-desc is:unread'
WHERE name = 'Continue Reading' AND default_filter = true;

COMMIT;
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ export const EmptyLibrary = (props: EmptyLibraryProps) => {
switch (props.searchTerm) {
case 'in:inbox':
return 'inbox'
case 'in:inbox sort:read-desc is:unread':
case 'in:inbox sort:read-desc is:reading':
return 'continue'
case 'in:library':
return 'non-feed'
Expand Down

0 comments on commit 768845e

Please sign in to comment.