1
0
mirror of https://github.com/aNNiMON/ffmpegbot synced 2024-09-19 22:54:20 +03:00

Fix NPE when no filenames provided

This commit is contained in:
aNNiMON 2023-10-21 21:35:07 +03:00
parent 6e58de0049
commit 4067963c12

View File

@ -14,6 +14,7 @@ public record FileInfo(FileType fileType, String fileId, String filename,
}
public String getExtension() {
if (filename == null) return "";
return FilenameUtils.getExtension(filename).toLowerCase(Locale.ROOT);
}
}