Skip to content

Commit d9067b3

Browse files
committed
Change default error message
1 parent 8496e90 commit d9067b3

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

doc/files/JSON-CONFIG-FILE.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,12 @@ Returned errors:
7878
{
7979
"error": JSONProperty.Errors.OBJECT_NON_VALID_PROPERTY,
8080
"property": "unrequired_property",
81-
"as_text": "The property 'unrequired_property' is not a valid one."
81+
"as_text": "Unkown property: 'unrequired_property', this property is not required."
8282
},
8383
{
8484
"error": JSONProperty.Errors.OBJECT_MISSING_PROPERTY,
8585
"property": "name",
86-
"as_text": "The property 'name' has not been specified."
86+
"as_text": "The required property 'name' is missing."
8787
}
8888
]
8989
```

doc/files/JSON-PROPERTY-OBJECT.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,13 +101,13 @@ Returned errors:
101101
"error": JSONProperty.Errors.OBJECT_NON_VALID_PROPERTY,
102102
"property": "unrequired_property",
103103
"context": "person",
104-
"as_text": "The property 'unrequired_property' is not a valid one, at 'person'."
104+
"as_text": "Unkown property: 'unrequired_property', this property is not required, at 'person'."
105105
},
106106
{
107107
"error": JSONProperty.Errors.OBJECT_MISSING_PROPERTY,
108108
"property": "name",
109109
"context": "person",
110-
"as_text": "The property 'name' has not been specified, at 'person'."
110+
"as_text": "The required property 'name' is missing, at 'person'."
111111
}
112112
]
113113
```

json_config_file/json_properties/json_property.gd

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,8 +114,8 @@ const MESSAGE_ARRAY_TWO_KEYS_ARE_EQUAL = "The array contains two objects with th
114114
const MESSAGE_COLOR_WRONG_SIZE = "The color is %d element(s) long, when it should be 3 to 4"
115115
const MESSAGE_COLOR_WRONG_TYPE = "Wrong type: expected 'integer' in the range [0, 255]"
116116
const MESSAGE_COLOR_OUT_OF_RANGE = "%d is out of the range [0, 255]"
117-
const MESSAGE_OBJECT_MISSING_PROPERTY = "The property '%s' has not been specified"
118-
const MESSAGE_OBJECT_NON_VALID_PROPERTY = "The property '%s' is not a valid one"
117+
const MESSAGE_OBJECT_MISSING_PROPERTY = "The required property '%s' is missing"
118+
const MESSAGE_OBJECT_NON_VALID_PROPERTY = "Unkown property: '%s', this property is not required"
119119
const MESSAGE_OBJECT_ONE_IS_REQUIRED = "One of this properties needs to be specified: %s"
120120
const MESSAGE_OBJECT_EXCLUSIVITY_ERROR = "This properties can not be present at the same time: %s"
121121
const MESSAGE_OBJECT_DEPENDENCY_ERROR = "'%s' property has been specified, but '%s' is missing"

0 commit comments

Comments
 (0)