Skip to content

Commit

Permalink
Just use davUser as account identifier for macOS log filename
Browse files Browse the repository at this point in the history
Signed-off-by: Claudio Cambra <[email protected]>
  • Loading branch information
claucambra authored and mgallien committed Nov 22, 2024
1 parent 9850434 commit 3f0e75b
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/gui/generalsettings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,13 @@ bool createDebugArchive(const QString &filename)
const auto xpc = fileProvider->xpc();
const auto vfsAccounts = OCC::Mac::FileProviderSettingsController::instance()->vfsEnabledAccounts();
for (const auto &accountUserIdAtHost : vfsAccounts) {
const auto vfsLogFilename = QStringLiteral("macOS_vfs_%1.log").arg(accountUserIdAtHost);
const auto accountState = OCC::AccountManager::instance()->accountFromUserId(accountUserIdAtHost);
if (!accountState) {
qWarning() << "Could not find account for" << accountUserIdAtHost;
continue;
}
const auto account = accountState->account();
const auto vfsLogFilename = QStringLiteral("macOS_vfs_%1.log").arg(account->davUser());
const auto vfsLogPath = tempDir.filePath(vfsLogFilename);
xpc->createDebugArchiveForExtension(accountUserIdAtHost, vfsLogPath);
zip.addLocalFile(vfsLogPath, vfsLogFilename);
Expand Down

0 comments on commit 3f0e75b

Please sign in to comment.