Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -212,7 +212,7 @@ async def preview_handler(event):
|
|
212 |
if user_id in states and states[user_id]:
|
213 |
# Send the current modification for preview
|
214 |
output_file_name = f"{user_id}_preview"
|
215 |
-
output_file = Fusion.saveSound(states[user_id]['audio'], output_file_name)
|
216 |
await event.edit("`Uploading...`", buttons=buttons)
|
217 |
# Edit the message and send the audio file in the edited message
|
218 |
await event.edit(file=output_file, text="`Preview the current modification:`", buttons=buttons)
|
@@ -229,7 +229,7 @@ async def send_handler(event):
|
|
229 |
if user_id in states and states[user_id]:
|
230 |
# Send the modified sound file
|
231 |
output_file_name = f"{user_id}_modified_audio"
|
232 |
-
output_file = Fusion.saveSound(states[user_id]["audio"], output_file_name)
|
233 |
await event.reply(file=output_file)
|
234 |
|
235 |
# Clean up - remove the user's state and the saved audio file
|
|
|
212 |
if user_id in states and states[user_id]:
|
213 |
# Send the current modification for preview
|
214 |
output_file_name = f"{user_id}_preview"
|
215 |
+
output_file = await Fusion.saveSound(states[user_id]['audio'], output_file_name)
|
216 |
await event.edit("`Uploading...`", buttons=buttons)
|
217 |
# Edit the message and send the audio file in the edited message
|
218 |
await event.edit(file=output_file, text="`Preview the current modification:`", buttons=buttons)
|
|
|
229 |
if user_id in states and states[user_id]:
|
230 |
# Send the modified sound file
|
231 |
output_file_name = f"{user_id}_modified_audio"
|
232 |
+
output_file = await Fusion.saveSound(states[user_id]["audio"], output_file_name)
|
233 |
await event.reply(file=output_file)
|
234 |
|
235 |
# Clean up - remove the user's state and the saved audio file
|