-
-
Save kelciour/9f501f675fedd3ee381f3a4647e9d1e5 to your computer and use it in GitHub Desktop.
Fix no sound on export
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import os | |
from anki.hooks import wrap | |
from anki.exporting import AnkiCollectionPackageExporter | |
def myDoExport(self, z, path, _old): | |
mdir = self.col.media.dir() | |
ret = _old(self, z, path) | |
os.chdir(mdir) | |
return ret | |
AnkiCollectionPackageExporter.doExport = wrap(AnkiCollectionPackageExporter.doExport, myDoExport, "around") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment