mirror of
https://github.com/HKUDS/nanobot.git
synced 2026-04-11 21:53:37 +00:00
Merge branch 'main' into pr-1784
This commit is contained in:
commit
757921fb27
@ -753,8 +753,9 @@ class FeishuChannel(BaseChannel):
|
||||
None, self._download_file_sync, message_id, file_key, msg_type
|
||||
)
|
||||
if not filename:
|
||||
ext = {"audio": ".opus", "media": ".mp4"}.get(msg_type, "")
|
||||
filename = f"{file_key[:16]}{ext}"
|
||||
filename = file_key[:16]
|
||||
if msg_type == "audio" and not filename.endswith(".opus"):
|
||||
filename = f"{filename}.opus"
|
||||
|
||||
if data and filename:
|
||||
file_path = media_dir / filename
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user