Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
katsuhira02 committed Jul 15, 2024
1 parent 34dea65 commit 85affa2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion supabase/functions/neuro-calls/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -812,7 +812,10 @@ botNeuroCalls.on("message:text", async (ctx: Context) => {
const telegram_id = ctx.from?.id.toString()
if (!telegram_id) throw new Error("No telegram_id")
const voice_id_synclabs = await getVoiceId(telegram_id)
if (!voice_id_synclabs) throw new Error("No voice_id_synclabs")
if (!voice_id_synclabs) {
await ctx.reply(lang ? "🔮 Вы еще не присвоили голос аватару. Либо дождитесь пока вам придет ответ о том что ваш Voice ID успешно присвоен. " : "🔮 You haven't assigned a voice to your avatar yet. Or wait for an answer about your Voice ID being successfully assigned.")
return
}
if (!query) throw new Error("No query")
const speech = await createSpeech(query, voice_id_synclabs)
console.log(speech, "speech")
Expand Down

0 comments on commit 85affa2

Please sign in to comment.