Skip to content

Commit 23e465e

Browse files
committed
fix copy constructor
1 parent 5d306c8 commit 23e465e

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

Discord.C++/Interaction.cpp

+14
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,26 @@ DiscordCPP::Interaction::Interaction(const json& data, const std::string& token)
2929

3030
DiscordCPP::Interaction::Interaction(const Interaction& old)
3131
: DiscordCPP::DiscordObject(old) {
32+
token = old.token;
33+
application_id = old.application_id;
34+
type = old.type;
35+
data = old.data;
36+
37+
guild_id = old.guild_id;
3238
if (old.guild != nullptr) {
3339
guild = new Guild(*old.guild);
3440
}
41+
42+
channel_id = old.channel_id;
3543
if (old.channel != nullptr) {
3644
channel = new Channel(*old.channel);
3745
}
46+
47+
member = old.member;
48+
user = old.user;
49+
message = old.message;
50+
locale = old.locale;
51+
guild_locale = old.guild_locale;
3852
}
3953

4054
DiscordCPP::Interaction::~Interaction() {

0 commit comments

Comments
 (0)