[Bug]: getAllPropertyNames error on type not present #3387
Labels
bug
macro changes
This issue adds or changes macro functions. Extra work is required (testing, wiki, code editor)
Describe the Bug
getAllPropertyNames(type, delim) creates an error causing macros to stop running where the type does not exist in the Camapaign Properties.
To Reproduce
[r: getAllPropertyNames("Franco_Prussian_Soldier_Specialist_Artillerest_16thCentury", "json")]
Expected Behaviour
I would expect it to return an empty set or false.
Without being able to determine what token types exist within the campaign there is no way to know if the function is safe to call.
Accordingly I would expect it to return something useful that can be handled in code if the type is not present.
Screenshots
No response
MapTool Info
1.11.4
Desktop
Win10
Additional Context
No response
The text was updated successfully, but these errors were encountered: