Do not throw error if text is empty

This commit is contained in:
Hongbo Wu 2022-09-07 22:56:37 +08:00
parent 8e8a6dccd0
commit 967fb3c6d5

View file

@ -160,9 +160,6 @@ export const textToSpeechStreamingHandler = Sentry.GCPFunction.wrapHttpFunction(
try {
const utteranceInput = req.body as UtteranceInput
if (!utteranceInput.text) {
return res.status(400).send({ errorCode: 'INVALID_DATA' })
}
const input: TextToSpeechInput = {
...utteranceInput,
textType: 'utterance',