Skip to content

Commit

Permalink
update standard for more standardizations
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacs committed Nov 21, 2017
1 parent ad2b547 commit 2ad741b
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions ini.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ function dotSplit (str) {
return str.replace(/\1/g, '\u0002LITERAL\\1LITERAL\u0002')
.replace(/\\\./g, '\u0001')
.split(/\./).map(function (part) {
return part.replace(/\1/g, '\\.')
return part.replace(/\1/g, '\\.')
.replace(/\2LITERAL\\1LITERAL\2/g, '\u0001')
})
})
}

function decode (str) {
Expand Down Expand Up @@ -149,9 +149,9 @@ function safe (val) {
val.match(/^\[/) ||
(val.length > 1 &&
isQuoted(val)) ||
val !== val.trim()) ?
JSON.stringify(val) :
val.replace(/;/g, '\\;').replace(/#/g, '\\#')
val !== val.trim())
? JSON.stringify(val)
: val.replace(/;/g, '\\;').replace(/#/g, '\\#')
}

function unsafe (val, doUnesc) {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
},
"dependencies": {},
"devDependencies": {
"standard": "^4.0.1",
"standard": "^10.0.3",
"tap": "^10.7.3"
},
"license": "ISC",
Expand Down

0 comments on commit 2ad741b

Please sign in to comment.