Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ci/clazy fixes #6135

Merged
merged 4 commits into from
Oct 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/gui/accountmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -490,7 +490,7 @@ AccountState *AccountManager::addAccount(const AccountPtr &newAccount)
return newAccountState;
}

void AccountManager::deleteAccount(AccountState *account)
void AccountManager::deleteAccount(OCC::AccountState *account)
{
const auto it = std::find(_accounts.begin(), _accounts.end(), account);
if (it == _accounts.end()) {
Expand Down
2 changes: 1 addition & 1 deletion src/gui/accountmanager.h
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public slots:
void save(bool saveCredentials = true);

/// Delete the AccountState
void deleteAccount(AccountState *account);
void deleteAccount(OCC::AccountState *account);

/// Remove all accounts
void shutdown();
Expand Down
2 changes: 1 addition & 1 deletion src/gui/filedetails/sharemodel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -945,7 +945,7 @@ void ShareModel::toggleShareNoteToRecipientFromQml(const QVariant &share, const
toggleShareNoteToRecipient(ptr, enable);
}

void ShareModel::changePermissionModeFromQml(const QVariant &share, const SharePermissionsMode permissionMode)
void ShareModel::changePermissionModeFromQml(const QVariant &share, const OCC::ShareModel::SharePermissionsMode permissionMode)
{
const auto sharePtr = share.value<SharePtr>();
if (sharePtr.isNull() || _sharePermissionsChangeInProgress) {
Expand Down
2 changes: 1 addition & 1 deletion src/gui/filedetails/sharemodel.h
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,7 @@ public slots:
void toggleShareExpirationDateFromQml(const QVariant &share, const bool enable) const;
void toggleShareNoteToRecipient(const OCC::SharePtr &share, const bool enable) const;
void toggleShareNoteToRecipientFromQml(const QVariant &share, const bool enable) const;
void changePermissionModeFromQml(const QVariant &share, const SharePermissionsMode permissionMode);
void changePermissionModeFromQml(const QVariant &share, const OCC::ShareModel::SharePermissionsMode permissionMode);

void setLinkShareLabel(const QSharedPointer<OCC::LinkShare> &linkShare, const QString &label) const;
void setLinkShareLabelFromQml(const QVariant &linkShare, const QString &label) const;
Expand Down
1 change: 0 additions & 1 deletion src/gui/sharemanager.h
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*

Check notice on line 1 in src/gui/sharemanager.h

View workflow job for this annotation

GitHub Actions / build

Run clang-format on src/gui/sharemanager.h

File src/gui/sharemanager.h (lines 22, 32, 123, 136, 206, 207, 208, 209, 210, 211, 212, 213, 214, 215, 216, 217, 218, 249, 269, 274, 275, 306, 337, 338, 339, 340, 341, 342, 343, 344, 345, 346, 361, 362, 392, 393, 408, 409, 410, 411, 442): Code does not conform to Custom style guidelines.
* Copyright (C) by Roeland Jago Douma <[email protected]>
*
* This program is free software; you can redistribute it and/or modify
Expand Down Expand Up @@ -310,7 +310,6 @@
void noteSet();
void nameSet();
void labelSet();
void hideDownloadSet();

private slots:
void slotNoteSet(const QJsonDocument &, const QVariant &value);
Expand Down
2 changes: 1 addition & 1 deletion src/libsync/networkjobs.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -836,7 +836,7 @@ bool AvatarJob::finished()
}
}
}
emit(avatarPixmap(avImage));
emit avatarPixmap(avImage);
return true;
}
#endif
Expand Down
4 changes: 2 additions & 2 deletions src/libsync/owncloudpropagator.h
Original file line number Diff line number Diff line change
Expand Up @@ -644,7 +644,7 @@ private slots:

signals:
void newItem(const OCC::SyncFileItemPtr &);
void itemCompleted(const SyncFileItemPtr &item, OCC::ErrorCategory category);
void itemCompleted(const OCC::SyncFileItemPtr &item, OCC::ErrorCategory category);
void progress(const OCC::SyncFileItem &, qint64 bytes);
void finished(OCC::SyncFileItem::Status status);

Expand Down Expand Up @@ -725,7 +725,7 @@ class CleanupPollsJob : public QObject
void start();
signals:
void finished();
void aborted(const QString &error, const ErrorCategory errorCategory);
void aborted(const QString &error, const OCC::ErrorCategory errorCategory);
private slots:
void slotPollFinished();
};
Expand Down
4 changes: 2 additions & 2 deletions src/libsync/syncengine.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ void SyncEngine::slotDiscoveryFinished()
}

if (_discoveryPhase->_hasDownloadRemovedItems && _discoveryPhase->_hasUploadErrorItems) {
for (const auto &item : _syncItems) {
for (const auto &item : qAsConst(_syncItems)) {
if (item->_instruction == CSYNC_INSTRUCTION_ERROR && item->_direction == SyncFileItem::Up) {
item->_instruction = CSYNC_INSTRUCTION_IGNORE;
}
Expand Down Expand Up @@ -919,7 +919,7 @@ void SyncEngine::slotDiscoveryFinished()

void SyncEngine::slotCleanPollsJobAborted(const QString &error, const ErrorCategory errorCategory)
{
syncError(error, errorCategory);
emit syncError(error, errorCategory);
finalize(false);
}

Expand Down
3 changes: 2 additions & 1 deletion test/testsecurefiledrop.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,8 @@ private slots:

bool isAnyFileDropFileMissing = false;

for (const auto &key : metadata->fileDrop().keys()) {
const auto allKeys = metadata->fileDrop().keys();
for (const auto &key : allKeys) {
if (std::find_if(metadata->files().constBegin(), metadata->files().constEnd(), [&key](const EncryptedFile &encryptedFile) {
return encryptedFile.encryptedFilename == key;
}) == metadata->files().constEnd()) {
Expand Down
Loading