diff --git a/AnkiDroid/src/main/java/com/ichi2/anki/export/ActivityExportingDelegate.kt b/AnkiDroid/src/main/java/com/ichi2/anki/export/ActivityExportingDelegate.kt index 1bc2fbaf7ea8..5d617228c0d4 100644 --- a/AnkiDroid/src/main/java/com/ichi2/anki/export/ActivityExportingDelegate.kt +++ b/AnkiDroid/src/main/java/com/ichi2/anki/export/ActivityExportingDelegate.kt @@ -121,7 +121,8 @@ class ActivityExportingDelegate(private val activity: AnkiActivity, private val } override fun exportDeckAsApkg(path: String?, did: DeckId, includeSched: Boolean, includeMedia: Boolean) { - val deckName = collectionSupplier.get().decks.name(did) + // files can't have `/` in their names + val deckName = collectionSupplier.get().decks.name(did).replace("/", "_") val exportPath = getExportFileName(path, deckName, includeSched) if (BackendFactory.defaultLegacySchema) {