Skip to content

Commit a996bb1

Browse files
authored
Merge pull request #9808 from nextcloud/codex/locate-usage-of-command_copy_securefiledrop_link
fix: remove unused COPY_SECUREFILEDROP_LINK socket command
2 parents 9516444 + 3574314 commit a996bb1

3 files changed

Lines changed: 0 additions & 17 deletions

File tree

src/gui/macOS/findersyncservice.mm

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,6 @@ - (void)executeMenuCommand:(NSString *)command
193193
static const QSet<QString> allowedCommands = {
194194
QStringLiteral("SHARE"),
195195
QStringLiteral("LEAVESHARE"),
196-
QStringLiteral("COPY_SECUREFILEDROP_LINK"),
197196
QStringLiteral("COPY_PRIVATE_LINK"),
198197
QStringLiteral("EMAIL_PRIVATE_LINK"),
199198
QStringLiteral("OPEN_PRIVATE_LINK"),
@@ -449,4 +448,3 @@ void sendMessage(const QString &message, bool = false) const override
449448

450449
} // namespace OCC
451450

452-

src/gui/socketapi/socketapi.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -906,20 +906,6 @@ class GetOrCreatePublicLinkShare : public QObject
906906

907907
#endif
908908

909-
void SocketApi::command_COPY_SECUREFILEDROP_LINK(const QString &localFile, SocketListener *)
910-
{
911-
const auto fileData = FileData::get(localFile);
912-
if (!fileData.folder) {
913-
return;
914-
}
915-
916-
const auto account = fileData.folder->accountState()->account();
917-
const auto getOrCreatePublicLinkShareJob = new GetOrCreatePublicLinkShare(account, fileData.serverRelativePath, true, this);
918-
connect(getOrCreatePublicLinkShareJob, &GetOrCreatePublicLinkShare::done, this, [](const QString &url) { copyUrlToClipboard(url); });
919-
connect(getOrCreatePublicLinkShareJob, &GetOrCreatePublicLinkShare::error, this, [=, this]() { emit shareCommandReceived(fileData.localPath); });
920-
getOrCreatePublicLinkShareJob->run();
921-
}
922-
923909
// Windows Shell / Explorer pinning fallbacks, see issue: https://github.com/nextcloud/desktop/issues/1599
924910
#ifdef Q_OS_WIN
925911
void SocketApi::command_COPYASPATH(const QString &localFile, SocketListener *)

src/gui/socketapi/socketapi.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,6 @@ private slots:
129129
Q_INVOKABLE void command_ENCRYPT(const QString &localFile, OCC::SocketListener *listener);
130130
Q_INVOKABLE void command_SHARE(const QString &localFile, OCC::SocketListener *listener);
131131
Q_INVOKABLE void command_LEAVESHARE(const QString &localFile, OCC::SocketListener *listener);
132-
Q_INVOKABLE void command_COPY_SECUREFILEDROP_LINK(const QString &localFile, OCC::SocketListener *listener);
133132
Q_INVOKABLE void command_COPY_PRIVATE_LINK(const QString &localFile, OCC::SocketListener *listener);
134133
Q_INVOKABLE void command_EMAIL_PRIVATE_LINK(const QString &localFile, OCC::SocketListener *listener);
135134
Q_INVOKABLE void command_OPEN_PRIVATE_LINK(const QString &localFile, OCC::SocketListener *listener);

0 commit comments

Comments
 (0)