From 6c0b89784899b3195dc13891b1f766a492b32aa4 Mon Sep 17 00:00:00 2001 From: sevenc-nanashi Date: Mon, 11 Sep 2023 00:32:50 +0900 Subject: [PATCH] Fix: nth(0) -> next() --- src/aivoice.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/aivoice.rs b/src/aivoice.rs index 8194a9b..18625f0 100644 --- a/src/aivoice.rs +++ b/src/aivoice.rs @@ -161,7 +161,7 @@ impl AiVoice { if !voice_preset_names.iter().any(|x| x == "AIVoiceVox") { self.host.add_voice_preset(VoicePreset { preset_name: "AIVoiceVox".to_string(), - voice_name: self.speakers.values().nth(0).unwrap().internal_name.clone(), + voice_name: self.speakers.values().next().unwrap().internal_name.clone(), volume: 1.0, speed: 1.0, pitch: 1.0,