Skip to content

Commit 79ddb6e

Browse files
committed
npm update
1 parent 0c960f2 commit 79ddb6e

File tree

7 files changed

+367
-288
lines changed

7 files changed

+367
-288
lines changed

package-lock.json

Lines changed: 357 additions & 280 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,14 @@
6464
"@typescript-eslint/parser": "^7.4.0",
6565
"cross-os": "^1.5.0",
6666
"eslint": "^8.57.0",
67-
"eslint-plugin-unicorn": "^52.0.0",
68-
"glob": "^10.3.12",
67+
"eslint-plugin-unicorn": "^54.0.0",
68+
"glob": "^11.0.0",
6969
"http-proxy-agent": "^7.0.2",
7070
"lodash.orderby": "^4.6.0",
7171
"mocha": "^10.2.0",
7272
"nyc": "^15.1.0",
7373
"open": "^10.1.0",
74-
"rimraf": "^5.0.5",
74+
"rimraf": "^6.0.1",
7575
"sinon": "^17.0.0",
7676
"source-map-support": "^0.5.21",
7777
"ts-node": "^10.9.1",

src/Documents/Indexes/IndexDefinitionHelper.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { StringUtil } from "../../Utility/StringUtil";
44
import * as XRegExp from "xregexp";
55
import { IndexSourceType } from "./IndexSourceType";
66

7-
const COMMENT_REGEX = XRegExp("(?:/\\*(?:[^*]|(?:\\*+[^*/]))*\\*+/)|(?://.*)", "gm");
7+
const COMMENT_REGEX = XRegExp(String.raw`(?:/\*(?:[^*]|(?:\*+[^*/]))*\*+/)|(?://.*)`, "gm");
88

99
export class IndexDefinitionHelper {
1010
public static detectStaticIndexType(map: string, reduce: string): IndexType {

src/Documents/Operations/Sorters/PutSortersOperation.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ class PutSortersCommand extends RavenCommand<void> implements IRaftCommand {
4242
throwError("InvalidArgumentException", "SortersToAdd cannot be null");
4343
}
4444

45-
if (sortersToAdd.findIndex(x => !x) > -1) {
45+
if (sortersToAdd.some(x => !x) ) {
4646
throwError("InvalidArgumentException", "Sorter cannot be null");
4747
}
4848

src/Documents/Session/IncludesUtil.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export class IncludesUtil {
3636
for (let i = 0; i < include.length; i++) {
3737
const ch = include.charAt(i);
3838
if (!(StringUtil.isLetter(ch) || StringUtil.isDigit(ch)) && ch !== "_" && ch !== ".") {
39-
escapedIncludeSetter(include.replace(/'/g, "\\'"));
39+
escapedIncludeSetter(include.replace(/'/g, String.raw`\'`));
4040
return true;
4141
}
4242
}

src/Utility/ObjectUtil.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,12 @@ export class ObjectUtil {
2323
* @param o Object to clone
2424
*/
2525
public static clone(o) {
26+
// eslint-disable-next-line unicorn/prefer-structured-clone
2627
return JSON.parse(JSON.stringify(o));
2728
}
2829

2930
public static deepJsonClone(o) {
31+
// eslint-disable-next-line unicorn/prefer-structured-clone
3032
return JSON.parse(JSON.stringify(o));
3133
}
3234

src/Utility/StringUtil.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { CasingConvention } from "./ObjectUtil";
66
import { StringBuilder } from "./StringBuilder";
77

88
export class StringUtil {
9-
private static readonly letterRe: RegExp = XRegExp("^\\p{L}$") as RegExp;
9+
private static readonly letterRe: RegExp = XRegExp(String.raw`^\p{L}$`) as RegExp;
1010
private static readonly digitRe: RegExp = /\d/;
1111

1212
public static leftPad(s: string, length: number, char: string) {
@@ -149,7 +149,7 @@ export class StringUtil {
149149
private static _escapeStringInternal(builder: StringBuilder, value: string) {
150150
let escaped = JSON.stringify(value);
151151

152-
escaped = escaped.replace(/'/g, "\\'");
152+
escaped = escaped.replace(/'/g, String.raw`\'`);
153153

154154
builder.append(escaped.substring(1, escaped.length - 1));
155155
}

0 commit comments

Comments
 (0)