diff --git a/scripts/shared/native.js b/scripts/shared/native.js index 421f77fe..413d5c23 100644 --- a/scripts/shared/native.js +++ b/scripts/shared/native.js @@ -67,7 +67,9 @@ function isNull(val) { function getEntityData(entity, dataName) { if(entity != null) { - return entity.getData(dataName); + if(entity.getData != null) { + return entity.getData(dataName); + } } return null; }