Rearrange

This commit is contained in:
Oleksii Holub 2026-06-18 10:32:49 +03:00 committed by GitHub
parent c19e42d4b8
commit 5d5bde3789
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -165,8 +165,6 @@ public abstract class ExportCommandBase : DiscordCommandBase
throw new CommandException("Option --media-dir cannot be used without --media.");
}
var unwrappedChannels = new List<Channel>(channels);
// Make sure the user does not try to export multiple channels into one file.
// Output path must either be a directory or contain template tokens for this to work.
// Validate this up-front, before fetching threads, because thread fetching can take a
@ -198,6 +196,8 @@ public abstract class ExportCommandBase : DiscordCommandBase
);
}
var unwrappedChannels = new List<Channel>(channels);
// Unwrap threads
if (ThreadInclusionMode != ThreadInclusionMode.None)
{