mirror of
https://github.com/nextcloud/desktop.git
synced 2024-10-24 13:25:52 +03:00
Fix typo.
This commit is contained in:
parent
c418e58f88
commit
f82893496b
6 changed files with 10 additions and 11 deletions
|
@ -40,7 +40,7 @@ Q_OBJECT
|
||||||
public:
|
public:
|
||||||
ShibbolethCredentials();
|
ShibbolethCredentials();
|
||||||
|
|
||||||
/* create a credidentials for an already connected account */
|
/* create a credentials for an already connected account */
|
||||||
ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc);
|
ShibbolethCredentials(const QNetworkCookie &cookie, Account *acc);
|
||||||
|
|
||||||
void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
|
void syncContextPreInit(CSYNC* ctx) Q_DECL_OVERRIDE;
|
||||||
|
|
|
@ -71,7 +71,7 @@ public:
|
||||||
enum State { Disconnected = 0, /// no network connection
|
enum State { Disconnected = 0, /// no network connection
|
||||||
Connected, /// account is online
|
Connected, /// account is online
|
||||||
SignedOut, /// Disconnected + credential token has been discarded
|
SignedOut, /// Disconnected + credential token has been discarded
|
||||||
InvalidCredidential /// The credidential are invalids and we are asking for them to the user
|
InvalidCredential /// The credentials are invalid and we are asking the user for them
|
||||||
};
|
};
|
||||||
|
|
||||||
QString davPath() const { return _davPath; }
|
QString davPath() const { return _davPath; }
|
||||||
|
|
|
@ -225,7 +225,7 @@ void Application::slotCheckConnection()
|
||||||
Account *account = AccountManager::instance()->account();
|
Account *account = AccountManager::instance()->account();
|
||||||
|
|
||||||
if( account ) {
|
if( account ) {
|
||||||
if (account->state() == Account::InvalidCredidential
|
if (account->state() == Account::InvalidCredential
|
||||||
|| account->state() == Account::SignedOut) {
|
|| account->state() == Account::SignedOut) {
|
||||||
//Do not try to connect if we are logged out
|
//Do not try to connect if we are logged out
|
||||||
if (!_userTriggeredConnect) {
|
if (!_userTriggeredConnect) {
|
||||||
|
@ -262,8 +262,8 @@ void Application::slotCredentialsFetched()
|
||||||
account->setState(Account::SignedOut);
|
account->setState(Account::SignedOut);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (account->state() == Account::InvalidCredidential) {
|
if (account->state() == Account::InvalidCredential) {
|
||||||
// Then we ask again for the credidentials if they are wrong again
|
// Then we ask again for the credentials if they are wrong again
|
||||||
account->setState(Account::Disconnected);
|
account->setState(Account::Disconnected);
|
||||||
}
|
}
|
||||||
slotCheckConnection();
|
slotCheckConnection();
|
||||||
|
@ -281,12 +281,11 @@ void Application::slotToggleFolderman(int state)
|
||||||
_checkConnectionTimer.start();
|
_checkConnectionTimer.start();
|
||||||
// fall through
|
// fall through
|
||||||
case Account::SignedOut:
|
case Account::SignedOut:
|
||||||
case Account::InvalidCredidential:
|
case Account::InvalidCredential:
|
||||||
folderMan->setSyncEnabled(false);
|
folderMan->setSyncEnabled(false);
|
||||||
folderMan->terminateSyncProcess();
|
folderMan->terminateSyncProcess();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Application::slotConnectionValidatorResult(ConnectionValidator::Status status)
|
void Application::slotConnectionValidatorResult(ConnectionValidator::Status status)
|
||||||
|
|
|
@ -170,8 +170,8 @@ void AbstractNetworkJob::slotFinished()
|
||||||
bool discard = finished();
|
bool discard = finished();
|
||||||
AbstractCredentials *creds = _account->credentials();
|
AbstractCredentials *creds = _account->credentials();
|
||||||
if (!creds->stillValid(_reply) &&! _ignoreCredentialFailure
|
if (!creds->stillValid(_reply) &&! _ignoreCredentialFailure
|
||||||
&& _account->state() != Account::InvalidCredidential) {
|
&& _account->state() != Account::InvalidCredential) {
|
||||||
_account->setState(Account::InvalidCredidential);
|
_account->setState(Account::InvalidCredential);
|
||||||
|
|
||||||
// invalidate & forget token/password
|
// invalidate & forget token/password
|
||||||
// but try to re-sign in.
|
// but try to re-sign in.
|
||||||
|
|
|
@ -146,7 +146,7 @@ void OwncloudSetupWizard::slotDetermineAuthType(const QString &urlString)
|
||||||
}
|
}
|
||||||
Account *account = _ocWizard->account();
|
Account *account = _ocWizard->account();
|
||||||
account->setUrl(url);
|
account->setUrl(url);
|
||||||
// Set fake credentials beforfe we check what credidential it actually is.
|
// Set fake credentials beforfe we check what credential it actually is.
|
||||||
account->setCredentials(CredentialsFactory::create("dummy"));
|
account->setCredentials(CredentialsFactory::create("dummy"));
|
||||||
CheckServerJob *job = new CheckServerJob(_ocWizard->account(), false, this);
|
CheckServerJob *job = new CheckServerJob(_ocWizard->account(), false, this);
|
||||||
job->setIgnoreCredentialFailure(true);
|
job->setIgnoreCredentialFailure(true);
|
||||||
|
|
|
@ -51,7 +51,7 @@ void QuotaInfo::slotAccountStateChanged(int state)
|
||||||
{
|
{
|
||||||
switch (state) {
|
switch (state) {
|
||||||
case Account::SignedOut: // fall through
|
case Account::SignedOut: // fall through
|
||||||
case Account::InvalidCredidential:
|
case Account::InvalidCredential:
|
||||||
case Account::Disconnected:
|
case Account::Disconnected:
|
||||||
_jobRestartTimer->stop();
|
_jobRestartTimer->stop();
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in a new issue