Skip to content

Commit

Permalink
🎨 Change method executor type
Browse files Browse the repository at this point in the history
  • Loading branch information
MisakaTAT committed Sep 5, 2024
1 parent 949e130 commit 1bf244e
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@
import com.mikuac.shiro.exception.ShiroException;
import lombok.SneakyThrows;
import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor;
import org.springframework.web.socket.WebSocketSession;

import java.util.Optional;
import java.util.concurrent.CompletableFuture;
import java.util.concurrent.Executor;
import java.util.concurrent.ScheduledFuture;
import java.util.concurrent.TimeUnit;

Expand Down Expand Up @@ -58,7 +58,11 @@ public static void handleReConnect(Bot bot, long xSelfId, WebSocketSession sessi
}

@SneakyThrows
public static Bot handleFirstConnect(long xSelfId, WebSocketSession session, BotFactory botFactory, CoreEvent coreEvent, Executor shiroTaskExecutor) {
public static Bot handleFirstConnect(
long xSelfId, WebSocketSession session,
BotFactory botFactory, CoreEvent coreEvent,
ThreadPoolTaskExecutor shiroTaskExecutor
) {
// if the session has never connected
// or has been handled
log.info("Account {} connected", xSelfId);
Expand Down

0 comments on commit 1bf244e

Please sign in to comment.