Add OGG and other audio format support (.ogg, .oga, .opus, .flac)
This commit is contained in:
@@ -99,7 +99,7 @@ async def create_transcription(
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
# Validate file type
|
# Validate file type
|
||||||
allowed_extensions = {'.mp3', '.mp4', '.mpeg', '.mpga', '.m4a', '.wav', '.webm'}
|
allowed_extensions = {'.mp3', '.mp4', '.mpeg', '.mpga', '.m4a', '.wav', '.webm', '.ogg', '.oga', '.opus', '.flac'}
|
||||||
file_ext = os.path.splitext(file.filename)[1].lower()
|
file_ext = os.path.splitext(file.filename)[1].lower()
|
||||||
|
|
||||||
if file_ext not in allowed_extensions:
|
if file_ext not in allowed_extensions:
|
||||||
|
|||||||
Reference in New Issue
Block a user