fix: remove deprecated Application::getTwitchAbstract (#5560)
This commit is contained in:
@@ -388,7 +388,7 @@ QString popup(const CommandContext &ctx)
|
||||
}
|
||||
|
||||
// Open channel passed as argument in a popup
|
||||
auto targetChannel = getApp()->getTwitchAbstract()->getOrAddChannel(target);
|
||||
auto targetChannel = getApp()->getTwitch()->getOrAddChannel(target);
|
||||
getApp()->getWindows()->openInPopup(targetChannel);
|
||||
|
||||
return "";
|
||||
@@ -530,8 +530,7 @@ QString sendRawMessage(const CommandContext &ctx)
|
||||
|
||||
if (ctx.channel->isTwitchChannel())
|
||||
{
|
||||
getApp()->getTwitchAbstract()->sendRawMessage(
|
||||
ctx.words.mid(1).join(" "));
|
||||
getApp()->getTwitch()->sendRawMessage(ctx.words.mid(1).join(" "));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -564,7 +563,7 @@ QString injectFakeMessage(const CommandContext &ctx)
|
||||
}
|
||||
|
||||
auto ircText = ctx.words.mid(1).join(" ");
|
||||
getApp()->getTwitchAbstract()->addFakeMessage(ircText);
|
||||
getApp()->getTwitch()->addFakeMessage(ircText);
|
||||
|
||||
return "";
|
||||
}
|
||||
@@ -663,7 +662,7 @@ QString openUsercard(const CommandContext &ctx)
|
||||
stripChannelName(channelName);
|
||||
|
||||
ChannelPtr channelTemp =
|
||||
getApp()->getTwitchAbstract()->getChannelOrEmpty(channelName);
|
||||
getApp()->getTwitch()->getChannelOrEmpty(channelName);
|
||||
|
||||
if (channelTemp->isEmpty())
|
||||
{
|
||||
|
||||
@@ -182,10 +182,9 @@ bool appendWhisperMessageWordsLocally(const QStringList &words)
|
||||
!(getSettings()->streamerModeSuppressInlineWhispers &&
|
||||
getApp()->getStreamerMode()->isEnabled()))
|
||||
{
|
||||
app->getTwitchAbstract()->forEachChannel(
|
||||
[&messagexD](ChannelPtr _channel) {
|
||||
_channel->addMessage(messagexD, MessageContext::Repost);
|
||||
});
|
||||
app->getTwitch()->forEachChannel([&messagexD](ChannelPtr _channel) {
|
||||
_channel->addMessage(messagexD, MessageContext::Repost);
|
||||
});
|
||||
}
|
||||
|
||||
return true;
|
||||
|
||||
@@ -179,7 +179,7 @@ void NotificationController::fetchFakeChannels()
|
||||
for (size_t i = 0; i < channelMap[Platform::Twitch].raw().size(); i++)
|
||||
{
|
||||
const auto &name = channelMap[Platform::Twitch].raw()[i];
|
||||
auto chan = getApp()->getTwitchAbstract()->getChannelOrEmpty(name);
|
||||
auto chan = getApp()->getTwitch()->getChannelOrEmpty(name);
|
||||
if (chan->isEmpty())
|
||||
{
|
||||
channels.push_back(name);
|
||||
|
||||
@@ -300,7 +300,7 @@ int ChannelRef::get_by_name(lua_State *L)
|
||||
lua_pushnil(L);
|
||||
return 1;
|
||||
}
|
||||
auto chn = getApp()->getTwitchAbstract()->getChannelOrEmpty(name);
|
||||
auto chn = getApp()->getTwitch()->getChannelOrEmpty(name);
|
||||
lua::push(L, chn);
|
||||
return 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user