mirror of
https://github.com/nextcloud/desktop.git
synced 2024-11-24 22:15:57 +03:00
FolderWizard: fix crash in FolderWizardRemotePath::slotHandleLsColNetworkError
The Job is a LsColJob, not a MkColJob! Reproduce by entering a name with invalid character that cause an error 400 in the folder wizard's remote path line edit. (Relates issue #5924)
This commit is contained in:
parent
7a96e8a292
commit
f707a43b3c
1 changed files with 3 additions and 1 deletions
|
@ -22,6 +22,7 @@
|
|||
#include "accountstate.h"
|
||||
#include "creds/abstractcredentials.h"
|
||||
#include "wizard/owncloudwizard.h"
|
||||
#include "asserts.h"
|
||||
|
||||
#include <QDesktopServices>
|
||||
#include <QDir>
|
||||
|
@ -229,7 +230,8 @@ void FolderWizardRemotePath::slotHandleMkdirNetworkError(QNetworkReply *reply)
|
|||
|
||||
void FolderWizardRemotePath::slotHandleLsColNetworkError(QNetworkReply * /*reply*/)
|
||||
{
|
||||
auto job = qobject_cast<MkColJob *>(sender());
|
||||
auto job = qobject_cast<LsColJob *>(sender());
|
||||
ASSERT(job);
|
||||
showWarn(tr("Failed to list a folder. Error: %1")
|
||||
.arg(job->errorStringParsingBody()));
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue