Skip to content

Commit

Permalink
Super small tweaks to #1912.
Browse files Browse the repository at this point in the history
  • Loading branch information
zachleat committed May 10, 2022
1 parent fe1036d commit 02b8459
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/TemplateData.js
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ class TemplateData {
// we can just join the array by a forbidden character ("/"" is chosen here, since it works on Linux, Mac and Windows).
// If at some point this isn't enough anymore, it would be possible to just use JSON.stringify(objectPathTarget) since that
// is guaranteed to work but is signifivcantly slower.
let objectPathTargetString = objectPathTarget.join("/");
let objectPathTargetString = objectPathTarget.join(path.sep);

// if two global files have the same path (but different extensions)
// and conflict, let’s merge them.
Expand Down
10 changes: 4 additions & 6 deletions test/TemplateDataTest.js
Original file line number Diff line number Diff line change
Expand Up @@ -474,12 +474,10 @@ test("Dots in datafile path (Issue #1242)", async (t) => {

let data = await dataObj.getData();

t.deepEqual(data, {
"xyz.dottest": {
hi: "bye",
test: {
abc: 42,
},
t.deepEqual(data["xyz.dottest"], {
hi: "bye",
test: {
abc: 42,
},
});
});
Expand Down

0 comments on commit 02b8459

Please sign in to comment.