Add t to onDispatch

This commit is contained in:
Sleepy Flower Girl
2022-02-17 21:08:23 -05:00
parent 442e9643cf
commit 6d858978c4
3 changed files with 2 additions and 6 deletions

View File

@@ -635,7 +635,6 @@ namespace SleepyDiscord {
virtual void onMessage (Message message );
virtual void onServer (Server server );
virtual void onChannel (Channel channel );
virtual void onDispatch (const json::Value& jsonMessage);
virtual void onInteraction (Interaction interaction) {}
virtual void onAppCommand (AppCommand appCommand ) {}
virtual void onEditAppCommand (AppCommand appCommand ) {}
@@ -644,6 +643,7 @@ namespace SleepyDiscord {
virtual void onDeleteStageInstance(StageInstance instance ) {}
virtual void onEditStageInstance (StageInstance instance ) {}
virtual void onUnknownEvent (std::string name, const json::Value& data); //for extending old library versions
virtual void onDispatch (const json::Value& t, json::Value& d) {}
//websocket stuff
virtual void onHeartbeat();

View File

@@ -700,7 +700,7 @@ namespace SleepyDiscord {
onUnknownEvent(json::toStdString(t), d);
break;
}
onDispatch(d);
onDispatch(t, d);
}
void BaseDiscordClient::processMessage(const WebSocketMessage message) {

View File

@@ -144,10 +144,6 @@ namespace SleepyDiscord {
}
void BaseDiscordClient::onDispatch(const json::Value& jsonMessage) {
}
void BaseDiscordClient::onInvaldSession() {
}