mirror of
https://github.com/Sheldan/abstracto.git
synced 2026-04-18 21:03:11 +00:00
[AB-80] fixing not cleaning up emote record when changing emote
This commit is contained in:
@@ -166,6 +166,7 @@ public class EmoteServiceBean implements EmoteService {
|
|||||||
.builder()
|
.builder()
|
||||||
.fake(true)
|
.fake(true)
|
||||||
.custom(false)
|
.custom(false)
|
||||||
|
.animated(false)
|
||||||
.emoteKey(emoteText)
|
.emoteKey(emoteText)
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -160,15 +160,16 @@ public class EmoteManagementServiceBean implements EmoteManagementService {
|
|||||||
if(fakeEmote.getCustom()) {
|
if(fakeEmote.getCustom()) {
|
||||||
log.debug("Setting existing emote (a: {}, c: {}, id: {}, discord id: {}) to new custom emote configuration: new id {}, animated {}.",
|
log.debug("Setting existing emote (a: {}, c: {}, id: {}, discord id: {}) to new custom emote configuration: new id {}, animated {}.",
|
||||||
emoteBeingSet.getAnimated(), emoteBeingSet.getCustom(), emoteBeingSet.getId(), emoteBeingSet.getEmoteId(), fakeEmote.getEmoteId(), fakeEmote.getAnimated());
|
emoteBeingSet.getAnimated(), emoteBeingSet.getCustom(), emoteBeingSet.getId(), emoteBeingSet.getEmoteId(), fakeEmote.getEmoteId(), fakeEmote.getAnimated());
|
||||||
emoteBeingSet.setCustom(fakeEmote.getCustom());
|
|
||||||
emoteBeingSet.setEmoteId(fakeEmote.getEmoteId());
|
emoteBeingSet.setEmoteId(fakeEmote.getEmoteId());
|
||||||
emoteBeingSet.setEmoteKey(fakeEmote.getEmoteKey());
|
emoteBeingSet.setAnimated(fakeEmote.getAnimated());
|
||||||
} else {
|
} else {
|
||||||
log.debug("Setting existing emote (a: {}, c: {}, id: {}, discord id: {}) to new default emote {}.",
|
log.debug("Setting existing emote (a: {}, c: {}, id: {}, discord id: {}) to new default emote {}.",
|
||||||
emoteBeingSet.getAnimated(), emoteBeingSet.getCustom(), emoteBeingSet.getId(), emoteBeingSet.getEmoteId(), fakeEmote.getEmoteKey());
|
emoteBeingSet.getAnimated(), emoteBeingSet.getCustom(), emoteBeingSet.getId(), emoteBeingSet.getEmoteId(), fakeEmote.getEmoteKey());
|
||||||
emoteBeingSet.setCustom(false);
|
emoteBeingSet.setEmoteId(null);
|
||||||
emoteBeingSet.setEmoteKey(fakeEmote.getEmoteKey());
|
emoteBeingSet.setAnimated(false);
|
||||||
}
|
}
|
||||||
|
emoteBeingSet.setCustom(fakeEmote.getCustom());
|
||||||
|
emoteBeingSet.setEmoteKey(fakeEmote.getEmoteKey());
|
||||||
return emoteBeingSet;
|
return emoteBeingSet;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user