From 0d3b74283723dc25deab372c813628e95e01f40f Mon Sep 17 00:00:00 2001 From: Hongbo Wu Date: Fri, 21 Jul 2023 18:03:57 +0800 Subject: [PATCH] limit 20k articles per pocket import --- packages/api/src/routers/svc/integrations.ts | 2 +- packages/web/pages/settings/integrations.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/api/src/routers/svc/integrations.ts b/packages/api/src/routers/svc/integrations.ts index 9e31458bd..111e0371f 100644 --- a/packages/api/src/routers/svc/integrations.ts +++ b/packages/api/src/routers/svc/integrations.ts @@ -263,7 +263,7 @@ export function integrationsServiceRouter() { total: offset, size: retrievedData.length, }) - } while (retrievedData.length > 0) + } while (retrievedData.length > 0 && offset < 20000) // limit to 20k pages } // update the integration's syncedAt and remove taskName diff --git a/packages/web/pages/settings/integrations.tsx b/packages/web/pages/settings/integrations.tsx index 6f09a6c84..33c316fcc 100644 --- a/packages/web/pages/settings/integrations.tsx +++ b/packages/web/pages/settings/integrations.tsx @@ -177,7 +177,7 @@ export default function Integrations(): JSX.Element { icon: '/static/icons/pocket.svg', title: 'Pocket', subText: - 'Pocket is a place to save articles, videos, and more. Our Pocket integration allows importing your Pocket library to Omnivore. Once connected we will asyncronously import all your Pocket articles into Omnivore, as this process is resource intensive it can take some time. You will receive an email when the process is completed.', + 'Pocket is a place to save articles, videos, and more. Our Pocket integration allows importing your Pocket library to Omnivore. Once connected we will asyncronously import all your Pocket articles into Omnivore, as this process is resource intensive it can take some time. You will receive an email when the process is completed. Limit 20k articles per import.', button: { text: pocketConnected ? 'Import' : 'Connect to Pocket', icon: isImporting(pocketConnected) ? (