Skip to content

Commit a0fdca7

Browse files
committed
fix(app): do not register protocol handlers on startup
1 parent 1eb6548 commit a0fdca7

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

src/app/main.cpp

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -205,17 +205,18 @@ int main(int argc, char *argv[])
205205

206206
#ifdef Q_OS_WIN32
207207
const static QHash<QString, QString> protocols = {
208-
{QStringLiteral("dash"), QStringLiteral("Dash Protocol")},
209-
{QStringLiteral("dash-plugin"), QStringLiteral("Dash Plugin Protocol")}
208+
{QStringLiteral("dash"), QStringLiteral("URL:Dash Protocol (Zeal)")},
209+
{QStringLiteral("dash-plugin"), QStringLiteral("URL:Dash Plugin Protocol (Zeal)")}
210210
};
211211

212+
if (clParams.registerProtocolHandlers) {
213+
registerProtocolHandlers(protocols, clParams.registerProtocolHandlers);
214+
return EXIT_SUCCESS;
215+
}
216+
212217
if (clParams.unregisterProtocolHandlers) {
213218
unregisterProtocolHandlers(protocols);
214219
return EXIT_SUCCESS;
215-
} else {
216-
registerProtocolHandlers(protocols, clParams.registerProtocolHandlers);
217-
if (clParams.registerProtocolHandlers)
218-
return EXIT_SUCCESS;
219220
}
220221
#endif
221222

0 commit comments

Comments
 (0)