We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7319c89 commit 1ede67cCopy full SHA for 1ede67c
src/main/java/xyz/htmlcsjs/coffeeFloppa/handlers/MessageHandler.java
@@ -24,6 +24,8 @@
24
25
import java.io.ByteArrayInputStream;
26
import java.nio.charset.StandardCharsets;
27
+import java.time.Duration;
28
+import java.time.Instant;
29
import java.util.*;
30
import java.util.stream.Collectors;
31
@@ -84,6 +86,9 @@ public static Mono<Object> edited(MessageUpdateEvent event) {
84
86
85
87
@NotNull
88
private static Mono<Object> executeMessage(Message message, String msgContent) {
89
+ if (Duration.between(message.getTimestamp(), Instant.now()).toHours() >= 2) {
90
+ return Mono.empty();
91
+ }
92
Channel channel = message.getChannel().block();
93
94
if (channel instanceof PrivateChannel dm) {
0 commit comments