Since _ls is now deprecated this is removed in favour of L1, I've also taken the oportunity to replace QStringLiteral and QLatin1String with their shortened form while we're at it. There are also a few instances where the string literal type has been switch, the general rule being to use the one that matches the function type or value being compared to avoid conversions.
17 lines
374 B
C++
17 lines
374 B
C++
// SPDX-FileCopyrightText: 2019 Kitsune Ral <Kitsune-Ral@users.sf.net>
|
|
// SPDX-License-Identifier: LGPL-2.1-or-later
|
|
|
|
#include "joinrulesevent.h"
|
|
|
|
using namespace Quotient;
|
|
|
|
QString JoinRulesEvent::joinRule() const
|
|
{
|
|
return fromJson<QString>(contentJson()["join_rule"_L1]);
|
|
}
|
|
|
|
QJsonArray JoinRulesEvent::allow() const
|
|
{
|
|
return contentJson()["allow"_L1].toArray();
|
|
}
|