mirror of
https://github.com/LuckPerms/LuckPerms.git
synced 2024-10-31 07:51:05 +01:00
Fix NPE with null context in FileWatcher
This commit is contained in:
parent
046daf23d0
commit
413e304845
@ -115,10 +115,14 @@ public class FileWatcher implements Runnable {
|
||||
List<WatchEvent<?>> watchEvents = key.pollEvents();
|
||||
|
||||
for (WatchEvent<?> event : watchEvents) {
|
||||
Path name = (Path) event.context();
|
||||
Path file = path.resolve(name);
|
||||
Path context = (Path) event.context();
|
||||
|
||||
String fileName = name.toString();
|
||||
if (context == null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
Path file = path.resolve(context);
|
||||
String fileName = context.toString();
|
||||
|
||||
if (internalChanges.containsKey(id + "/" + fileName)) {
|
||||
// This file was modified by the system.
|
||||
|
Loading…
Reference in New Issue
Block a user