From 3396a5b3cdc224586f13a628c33fcc4661c62269 Mon Sep 17 00:00:00 2001 From: OMGeeky Date: Fri, 28 Jun 2024 22:51:47 +0200 Subject: [PATCH] fetch for all users, not only the amount specified for max_items_to_process (since there is no ordering, some might never be fetched like this) --- src/client.rs | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/client.rs b/src/client.rs index b9d65bd..29144c1 100644 --- a/src/client.rs +++ b/src/client.rs @@ -5,7 +5,6 @@ use twba_local_db::entities::videos::ActiveModel; use twba_local_db::prelude::{Status, Users, UsersColumn, Videos, VideosColumn}; use twba_local_db::re_exports::sea_orm::{ ActiveModelTrait, ActiveValue, ColumnTrait, DatabaseConnection, EntityTrait, QueryFilter, - QuerySelect, }; use twba_twitch_data::TwitchClient; @@ -29,7 +28,6 @@ impl<'a> FetcherClient<'a> { pub(crate) async fn fetch_new_videos(&self) -> Result<()> { let users = Users::find() .filter(UsersColumn::Active.eq(true)) - .limit(self.conf.max_items_to_process) .all(&self.db) .await?; info!("Fetching videos for {} users", users.len());