Skip to content

Commit

Permalink
bring back the null and dictnull
Browse files Browse the repository at this point in the history
  • Loading branch information
jginternational committed Feb 9, 2022
1 parent c3146f8 commit 207d242
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions kratos.gid/scripts/Writing/WriteProjectParameters.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,11 @@ proc write::tcl2json { value } {
#if {$type ne "dict" && [llength $value]>1 && [string index $value 0] eq "\{"} { W "$value as list"; set type list}
#if {$type eq "exprcode"} {set type list; W "$type -> $value"}
switch $type {
string {
if {$value eq "null"} {return null}
if {$value eq "dictnull"} {return {{}}}
return [json::write string $value]
}
dict {
return [json::write object {*}[
dict map {k v} $value {tcl2json $v}]]
Expand Down

0 comments on commit 207d242

Please sign in to comment.