$objectHasProperty
$objectHasProperty checks if a given object contains a specified property and returns true or false.
Usage
$objectHasProperty[objectName;property]Parameters
| Field | Type | Description | Required |
|---|---|---|---|
| objectName | string | The name of the object to check. | true |
| property | string | The property name to look for. | true |
Example(s)
This example creates an object named Name and then checks if it has the property Leref:
1client.command({2 name: "objectHasProperty",3 code: `4 $objectHasProperty[Name;Leref] $comment[true]5
6 $createObject[Name;{7 "Leref": "Ferel",8 "aoi.js": "dbd.js"9 }]10 `11});