classlib: fix missing .shift() in ReferenceQueue.poll (#852)

This commit is contained in:
Jonathan Coates 2023-11-08 08:07:31 +00:00 committed by GitHub
parent 8f8b33c0b1
commit 2256b293ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -28,6 +28,6 @@ function init() {
}
function poll() {
var value = this[teavm_javaField("java.lang.ref.ReferenceQueue", "inner")];
var value = this[teavm_javaField("java.lang.ref.ReferenceQueue", "inner")].shift();
return typeof value !== 'undefined' ? value : null;
}