geforkt von Mirrors/FastAsyncWorldEdit
Don't initialise a DiskOptimisedClipboard before checking for an existing one in the LocalSession when using loadClipboardFromDisk (#1731)
Dieser Commit ist enthalten in:
Ursprung
b85888806a
Commit
267dc153f0
@ -463,7 +463,6 @@ public interface Player extends Entity, Actor {
|
|||||||
);
|
);
|
||||||
try {
|
try {
|
||||||
if (file.exists() && file.length() > 5) {
|
if (file.exists() && file.length() > 5) {
|
||||||
DiskOptimizedClipboard doc = new DiskOptimizedClipboard(file);
|
|
||||||
LocalSession session = getSession();
|
LocalSession session = getSession();
|
||||||
try {
|
try {
|
||||||
if (session.getClipboard() != null) {
|
if (session.getClipboard() != null) {
|
||||||
@ -471,9 +470,10 @@ public interface Player extends Entity, Actor {
|
|||||||
}
|
}
|
||||||
} catch (EmptyClipboardException ignored) {
|
} catch (EmptyClipboardException ignored) {
|
||||||
}
|
}
|
||||||
|
DiskOptimizedClipboard doc = new DiskOptimizedClipboard(file);
|
||||||
Clipboard clip = doc.toClipboard();
|
Clipboard clip = doc.toClipboard();
|
||||||
ClipboardHolder holder = new ClipboardHolder(clip);
|
ClipboardHolder holder = new ClipboardHolder(clip);
|
||||||
getSession().setClipboard(holder);
|
session.setClipboard(holder);
|
||||||
}
|
}
|
||||||
} catch (FaweClipboardVersionMismatchException e) {
|
} catch (FaweClipboardVersionMismatchException e) {
|
||||||
print(Caption.of("fawe.error.clipboard.on.disk.version.mismatch"));
|
print(Caption.of("fawe.error.clipboard.on.disk.version.mismatch"));
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren