diff --git a/src/libpoketube/libpoketube-core.js b/src/libpoketube/libpoketube-core.js index fa9ae306..4425128a 100644 --- a/src/libpoketube/libpoketube-core.js +++ b/src/libpoketube/libpoketube-core.js @@ -37,8 +37,10 @@ function getJson(str) { } function checkUnexistingObject(obj) { - if (Object.hasOwn(obj, "authorId")) { - return true; + if (obj) { + if ("authorId" in obj) { + return true; + } } }