aboutsummaryrefslogtreecommitdiff
path: root/lib/csapi/pushrules.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/csapi/pushrules.cpp')
-rw-r--r--lib/csapi/pushrules.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/csapi/pushrules.cpp b/lib/csapi/pushrules.cpp
index 0d840788..6b0effd4 100644
--- a/lib/csapi/pushrules.cpp
+++ b/lib/csapi/pushrules.cpp
@@ -9,12 +9,12 @@ using namespace Quotient;
QUrl GetPushRulesJob::makeRequestUrl(QUrl baseUrl)
{
return BaseJob::makeRequestUrl(
- std::move(baseUrl), makePath("/_matrix/client/r0", "/pushrules"));
+ std::move(baseUrl), makePath("/_matrix/client/v3", "/pushrules"));
}
GetPushRulesJob::GetPushRulesJob()
: BaseJob(HttpVerb::Get, QStringLiteral("GetPushRulesJob"),
- makePath("/_matrix/client/r0", "/pushrules"))
+ makePath("/_matrix/client/v3", "/pushrules"))
{
addExpectedKey("global");
}
@@ -23,14 +23,14 @@ QUrl GetPushRuleJob::makeRequestUrl(QUrl baseUrl, const QString& scope,
const QString& kind, const QString& ruleId)
{
return BaseJob::makeRequestUrl(std::move(baseUrl),
- makePath("/_matrix/client/r0", "/pushrules/",
+ makePath("/_matrix/client/v3", "/pushrules/",
scope, "/", kind, "/", ruleId));
}
GetPushRuleJob::GetPushRuleJob(const QString& scope, const QString& kind,
const QString& ruleId)
: BaseJob(HttpVerb::Get, QStringLiteral("GetPushRuleJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId))
{}
@@ -39,14 +39,14 @@ QUrl DeletePushRuleJob::makeRequestUrl(QUrl baseUrl, const QString& scope,
const QString& ruleId)
{
return BaseJob::makeRequestUrl(std::move(baseUrl),
- makePath("/_matrix/client/r0", "/pushrules/",
+ makePath("/_matrix/client/v3", "/pushrules/",
scope, "/", kind, "/", ruleId));
}
DeletePushRuleJob::DeletePushRuleJob(const QString& scope, const QString& kind,
const QString& ruleId)
: BaseJob(HttpVerb::Delete, QStringLiteral("DeletePushRuleJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId))
{}
@@ -65,7 +65,7 @@ SetPushRuleJob::SetPushRuleJob(const QString& scope, const QString& kind,
const QVector<PushCondition>& conditions,
const QString& pattern)
: BaseJob(HttpVerb::Put, QStringLiteral("SetPushRuleJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId),
queryToSetPushRule(before, after))
{
@@ -81,7 +81,7 @@ QUrl IsPushRuleEnabledJob::makeRequestUrl(QUrl baseUrl, const QString& scope,
const QString& ruleId)
{
return BaseJob::makeRequestUrl(std::move(baseUrl),
- makePath("/_matrix/client/r0", "/pushrules/",
+ makePath("/_matrix/client/v3", "/pushrules/",
scope, "/", kind, "/", ruleId,
"/enabled"));
}
@@ -90,7 +90,7 @@ IsPushRuleEnabledJob::IsPushRuleEnabledJob(const QString& scope,
const QString& kind,
const QString& ruleId)
: BaseJob(HttpVerb::Get, QStringLiteral("IsPushRuleEnabledJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId, "/enabled"))
{
addExpectedKey("enabled");
@@ -100,7 +100,7 @@ SetPushRuleEnabledJob::SetPushRuleEnabledJob(const QString& scope,
const QString& kind,
const QString& ruleId, bool enabled)
: BaseJob(HttpVerb::Put, QStringLiteral("SetPushRuleEnabledJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId, "/enabled"))
{
QJsonObject _data;
@@ -113,7 +113,7 @@ QUrl GetPushRuleActionsJob::makeRequestUrl(QUrl baseUrl, const QString& scope,
const QString& ruleId)
{
return BaseJob::makeRequestUrl(std::move(baseUrl),
- makePath("/_matrix/client/r0", "/pushrules/",
+ makePath("/_matrix/client/v3", "/pushrules/",
scope, "/", kind, "/", ruleId,
"/actions"));
}
@@ -122,7 +122,7 @@ GetPushRuleActionsJob::GetPushRuleActionsJob(const QString& scope,
const QString& kind,
const QString& ruleId)
: BaseJob(HttpVerb::Get, QStringLiteral("GetPushRuleActionsJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId, "/actions"))
{
addExpectedKey("actions");
@@ -133,7 +133,7 @@ SetPushRuleActionsJob::SetPushRuleActionsJob(const QString& scope,
const QString& ruleId,
const QVector<QVariant>& actions)
: BaseJob(HttpVerb::Put, QStringLiteral("SetPushRuleActionsJob"),
- makePath("/_matrix/client/r0", "/pushrules/", scope, "/", kind,
+ makePath("/_matrix/client/v3", "/pushrules/", scope, "/", kind,
"/", ruleId, "/actions"))
{
QJsonObject _data;