mirror of
https://github.com/flibusta-apps/telegram_files_cache_server.git
synced 2025-12-06 14:45:36 +01:00
Fix
This commit is contained in:
@@ -3,6 +3,7 @@ pub mod download_utils;
|
|||||||
pub mod telegram_files;
|
pub mod telegram_files;
|
||||||
pub mod downloader;
|
pub mod downloader;
|
||||||
|
|
||||||
|
use chrono::Duration;
|
||||||
use tracing::log;
|
use tracing::log;
|
||||||
|
|
||||||
use crate::{prisma::cached_file, views::Database};
|
use crate::{prisma::cached_file, views::Database};
|
||||||
@@ -135,8 +136,11 @@ pub async fn get_books_for_update() -> Result<Vec<BaseBook>, Box<dyn std::error:
|
|||||||
|
|
||||||
let page_size = 50;
|
let page_size = 50;
|
||||||
|
|
||||||
let uploaded_gte = "".to_string();
|
let now = chrono::offset::Utc::now();
|
||||||
let uploaded_lte = "".to_string();
|
let subset_3 = now - Duration::days(3);
|
||||||
|
|
||||||
|
let uploaded_gte = subset_3.format("%Y-%m-%d").to_string();
|
||||||
|
let uploaded_lte = now.format("%Y-%m-%d").to_string();
|
||||||
|
|
||||||
let first_page = match get_books(
|
let first_page = match get_books(
|
||||||
1,
|
1,
|
||||||
|
|||||||
Reference in New Issue
Block a user