The serializer can be null
But this will cause issues when trying to register objects
Dieser Commit ist enthalten in:
Ursprung
11ba322b5f
Commit
7077037bb7
@ -542,9 +542,9 @@ public class WrappedDataWatcher extends AbstractWrapper implements Iterable<Wrap
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Gets this watcher object's serializer.
|
* Gets this watcher object's serializer. Will return null if the serializer was never specified.
|
||||||
*
|
*
|
||||||
* @return The serializer
|
* @return The serializer, or null
|
||||||
*/
|
*/
|
||||||
public Serializer getSerializer() {
|
public Serializer getSerializer() {
|
||||||
if (getSerializer == null) {
|
if (getSerializer == null) {
|
||||||
@ -553,12 +553,15 @@ public class WrappedDataWatcher extends AbstractWrapper implements Iterable<Wrap
|
|||||||
}
|
}
|
||||||
|
|
||||||
Object serializer = getSerializer.invoke(handle);
|
Object serializer = getSerializer.invoke(handle);
|
||||||
|
if (serializer != null) {
|
||||||
Serializer wrapper = Registry.fromHandle(serializer);
|
Serializer wrapper = Registry.fromHandle(serializer);
|
||||||
if (wrapper != null) {
|
if (wrapper != null) {
|
||||||
return wrapper;
|
return wrapper;
|
||||||
|
} else {
|
||||||
|
return new Serializer(null, serializer, false);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
return new Serializer(null, serializer, false);
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren