refactor: Consolidate item content filtering into a single filter string
Co-authored-by: aider (openai/andrew/openrouter/deepseek/deepseek-chat-v3.1) <aider@aider.chat>
This commit is contained in:
@@ -139,19 +139,11 @@ impl ItemService {
|
||||
&self,
|
||||
conn: &Connection,
|
||||
id: i64,
|
||||
head_bytes: Option<usize>,
|
||||
head_words: Option<usize>,
|
||||
head_lines: Option<usize>,
|
||||
tail_bytes: Option<usize>,
|
||||
tail_words: Option<usize>,
|
||||
tail_lines: Option<usize>,
|
||||
line_start: Option<usize>,
|
||||
line_end: Option<usize>,
|
||||
grep: Option<String>,
|
||||
filter: Option<String>,
|
||||
) -> Result<(Vec<u8>, String, bool), CoreError> {
|
||||
// Use streaming approach to handle all filtering options consistently
|
||||
let (mut reader, mime_type, is_binary) = self.get_item_content_info_streaming(
|
||||
conn, id, None
|
||||
conn, id, filter
|
||||
)?;
|
||||
|
||||
// Read all the filtered content into a buffer
|
||||
|
||||
Reference in New Issue
Block a user