Skip to content

Commit

Permalink
Merge pull request #468 from microsoft/main
Browse files Browse the repository at this point in the history
Create a new pull request by comparing changes across two branches
  • Loading branch information
GulajavaMinistudio authored Aug 28, 2023
2 parents 04f9e70 + 27a5bdd commit cd3aff4
Show file tree
Hide file tree
Showing 75 changed files with 2,066 additions and 215 deletions.
126 changes: 79 additions & 47 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion scripts/errorCheck.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ async function checkSourceFiles() {
let count = 0;
console.log("== List of errors not used in source ==");
for (const errName of errorNames) {
if (allSrc.indexOf(errName) < 0) {
if (!allSrc.includes(errName)) {
console.log(errName);
count++;
}
Expand Down
2 changes: 1 addition & 1 deletion scripts/eslint/rules/argument-trivia.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ module.exports = createRule({
}
}

const hasNewLine = sourceCodeText.slice(commentRangeEnd, argRangeStart).indexOf("\n") >= 0;
const hasNewLine = sourceCodeText.slice(commentRangeEnd, argRangeStart).includes("\n");
if (argRangeStart !== commentRangeEnd + 1 && !hasNewLine) {
// TODO(jakebailey): range should be whitespace
context.report({
Expand Down
2 changes: 1 addition & 1 deletion scripts/update-experimental-branches.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ async function main() {
const mergeTree = runSequence([
["git", ["merge-tree", mergeBase.trim(), branch, "experimental"]],
]);
if (mergeTree.indexOf(`===${"="}===`) >= 0) { // 7 equals is the center of the merge conflict marker
if (mergeTree.includes(`===${"="}===`)) { // 7 equals is the center of the merge conflict marker
throw new Error(`Merge conflict detected involving PR ${branch} with other experiment`);
}
// Merge (always producing a merge commit)
Expand Down
2 changes: 1 addition & 1 deletion src/cancellationToken/cancellationToken.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ function createCancellationToken(args: string[]): ServerCancellationToken {
// in this case pipe name will be build dynamically as <cancellationPipeName><request_seq>.
if (cancellationPipeName.charAt(cancellationPipeName.length - 1) === "*") {
const namePrefix = cancellationPipeName.slice(0, -1);
if (namePrefix.length === 0 || namePrefix.indexOf("*") >= 0) {
if (namePrefix.length === 0 || namePrefix.includes("*")) {
throw new Error("Invalid name for template cancellation pipe: it should have length greater than 2 characters and contain only one '*'.");
}
let perRequestPipeName: string | undefined;
Expand Down
Loading

0 comments on commit cd3aff4

Please sign in to comment.