From 3611c93a4a4a253f4aa7d462ae976046bd8bf1b4 Mon Sep 17 00:00:00 2001 From: Andrew Phillips Date: Mon, 25 Aug 2025 21:07:48 -0300 Subject: [PATCH] fix: update imports and correct stream type Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) --- src/services/async_item_service.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/services/async_item_service.rs b/src/services/async_item_service.rs index 0b3b991..f2e7a66 100644 --- a/src/services/async_item_service.rs +++ b/src/services/async_item_service.rs @@ -3,9 +3,11 @@ use crate::services::item_service::ItemService; use crate::services::types::{ItemWithContent, ItemWithMeta}; use rusqlite::Connection; use std::collections::HashMap; +use std::io::Read; use std::path::PathBuf; use std::sync::Arc; use tokio::sync::Mutex; +use tokio_util::io::ReaderStream; /// An asynchronous wrapper around the `ItemService` for use in async contexts like the web server. /// It uses `tokio::task::spawn_blocking` to run synchronous database and filesystem operations @@ -207,7 +209,7 @@ impl AsyncItemService { } // Create a stream that reads the content in chunks - let stream = tokio_stream::wrappers::ReaderStream::new(reader); + let stream = ReaderStream::new(reader); // If length is specified, we need to limit the stream let limited_stream = if length > 0 {