assistant: Add implementation for /delta
argument completion (#19693)
This PR fixes a panic that could occur when trying to complete arguments for the `/delta` slash command. We were using `unimplemented!()` instead of providing a default no-op implementation like we do for other slash commands that do not support completing arguments. Closes https://github.com/zed-industries/zed/issues/19686. Release Notes: - Fixed a panic that could occur when trying to complete arguments with the `/delta` command.
This commit is contained in:
parent
499e1459eb
commit
b5f816dde5
1 changed files with 2 additions and 2 deletions
|
@ -1,5 +1,5 @@
|
|||
use crate::slash_command::file_command::{FileCommandMetadata, FileSlashCommand};
|
||||
use anyhow::Result;
|
||||
use anyhow::{anyhow, Result};
|
||||
use assistant_slash_command::{
|
||||
ArgumentCompletion, SlashCommand, SlashCommandOutput, SlashCommandOutputSection,
|
||||
SlashCommandResult,
|
||||
|
@ -38,7 +38,7 @@ impl SlashCommand for DeltaSlashCommand {
|
|||
_workspace: Option<WeakView<Workspace>>,
|
||||
_cx: &mut WindowContext,
|
||||
) -> Task<Result<Vec<ArgumentCompletion>>> {
|
||||
unimplemented!()
|
||||
Task::ready(Err(anyhow!("this command does not require argument")))
|
||||
}
|
||||
|
||||
fn run(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue