Type aliases in .convert method

This commit is contained in:
nathannathant
2021-03-15 14:26:32 -07:00
parent 0433d14033
commit e5ce0ee20a
+3
View File
@@ -224,11 +224,14 @@ class Track:
assert self.__is_downloaded, "track must be downloaded before conversion"
CONV_CLASS = {
"FLAC": converter.FLAC,
"ALAC": converter.ALAC,
"MP3": converter.LAME,
"OPUS": converter.OPUS,
"OGG": converter.Vorbis,
"VORBIS": converter.Vorbis,
"AAC": converter.AAC,
"M4A": converter.AAC,
}
engine = CONV_CLASS[codec.upper()](