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() {
|
||||
if (getSerializer == null) {
|
||||
@ -553,13 +553,16 @@ public class WrappedDataWatcher extends AbstractWrapper implements Iterable<Wrap
|
||||
}
|
||||
|
||||
Object serializer = getSerializer.invoke(handle);
|
||||
|
||||
if (serializer != null) {
|
||||
Serializer wrapper = Registry.fromHandle(serializer);
|
||||
if (wrapper != null) {
|
||||
return wrapper;
|
||||
} else {
|
||||
return new Serializer(null, serializer, false);
|
||||
}
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren