From 7c4274f7ed9daea0993f817abbd673e419f2aa45 Mon Sep 17 00:00:00 2001 From: ChomeNS <95471003+ChomeNS@users.noreply.github.com> Date: Sun, 27 Aug 2023 11:29:57 +0700 Subject: [PATCH] fix error not getting thrown --- .../chayapak/chomens_bot/commands/MusicCommand.java | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/MusicCommand.java b/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/MusicCommand.java index 0c38727..c13b782 100644 --- a/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/MusicCommand.java +++ b/src/main/java/land/chipmunk/chayapak/chomens_bot/commands/MusicCommand.java @@ -268,9 +268,11 @@ public class MusicCommand extends Command { index += eachSize; list.clear(); } - } catch (NotDirectoryException e) { + } catch (NoSuchFileException e) { return Component.text("Directory doesn't exist").color(NamedTextColor.RED); - } catch (IOException ignored) {} + } catch (IOException e) { + e.printStackTrace(); + } return null; }