mirror of
https://github.com/flynx/pWiki.git
synced 2025-12-17 08:31:38 +00:00
added data separation between the store and client...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
1da5dd7830
commit
56065a128c
6
pwiki.js
6
pwiki.js
@ -141,11 +141,13 @@ module.pWikiData = {
|
||||
// XXX should from be pattern compatible???
|
||||
data: function(path, value){
|
||||
if(value == null){
|
||||
return this.__data ? this.__data[path] : null
|
||||
return this.__data ?
|
||||
JSON.parse(JSON.stringify(this.__data[path]))
|
||||
: null
|
||||
|
||||
} else {
|
||||
this.__data = this.__data || {}
|
||||
this.__data[path] = value
|
||||
this.__data[path] = JSON.parse(JSON.stringify(value))
|
||||
return this
|
||||
}
|
||||
},
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user