mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-02-17 03:20:02 +00:00
Freeze the entire tiddler object
As seen in the first pass of #2247, it was previously inadvertently possible for callers to modify the tiddler object itself by adding and replacing properties.
This commit is contained in:
parent
8904a6dba6
commit
b47f505588
@ -812,6 +812,7 @@ $tw.Tiddler = function(/* [fields,] fields */) {
|
||||
}
|
||||
// Freeze the tiddler against modification
|
||||
Object.freeze(this.fields);
|
||||
Object.freeze(this);
|
||||
};
|
||||
|
||||
$tw.Tiddler.prototype.hasField = function(field) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user