mirror of
https://github.com/AppFlowy-IO/AppFlowy.git
synced 2024-08-30 18:12:39 +00:00
chore: fix rustfmt ci test (#5664)
This commit is contained in:
parent
e1c68c1b72
commit
50f5be3e75
@ -122,7 +122,8 @@ impl ResponseParser for ChatRelatedQuestionsResponseParser {
|
|||||||
fn parse_json(json: JsonValue) -> Result<Self::ValueType, RemoteError> {
|
fn parse_json(json: JsonValue) -> Result<Self::ValueType, RemoteError> {
|
||||||
json
|
json
|
||||||
.get("data")
|
.get("data")
|
||||||
.and_then(|data| data.as_array()).cloned()
|
.and_then(|data| data.as_array())
|
||||||
|
.cloned()
|
||||||
.ok_or(RemoteError::ParseResponse(json))
|
.ok_or(RemoteError::ParseResponse(json))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -72,7 +72,6 @@ impl LocalAITest {
|
|||||||
) -> String {
|
) -> String {
|
||||||
let plugin = self.manager.get_plugin(plugin_id).await.unwrap();
|
let plugin = self.manager.get_plugin(plugin_id).await.unwrap();
|
||||||
let operation = ChatPluginOperation::new(plugin);
|
let operation = ChatPluginOperation::new(plugin);
|
||||||
|
|
||||||
|
|
||||||
operation.send_message(chat_id, message).await.unwrap()
|
operation.send_message(chat_id, message).await.unwrap()
|
||||||
}
|
}
|
||||||
@ -95,7 +94,7 @@ impl LocalAITest {
|
|||||||
) -> Vec<serde_json::Value> {
|
) -> Vec<serde_json::Value> {
|
||||||
let plugin = self.manager.get_plugin(plugin_id).await.unwrap();
|
let plugin = self.manager.get_plugin(plugin_id).await.unwrap();
|
||||||
let operation = ChatPluginOperation::new(plugin);
|
let operation = ChatPluginOperation::new(plugin);
|
||||||
|
|
||||||
operation.get_related_questions(chat_id).await.unwrap()
|
operation.get_related_questions(chat_id).await.unwrap()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user