remove_property
Jump to navigation
Jump to search
Function Syntax
string remove_property( string prop, boolean? global )
- Removes or resets a property and returns its previous value.
- prop: Property name
- global: If
true
, removes a global property. Iffalse
, removes a user property. If omitted, this checks both user and global properties.
If the property has a default value, it will be reset to its default value instead.
This function was added in r17892.
Code Samples
Remove a property named myPref
and print its previous value.
print( "Removed myPref, old value was " + remove_property( "myPref" ) );