Skip to content

Commit

Permalink
chore: rename
Browse files Browse the repository at this point in the history
  • Loading branch information
RamIdeas committed Sep 11, 2024
1 parent 18a953d commit 67876f5
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/wrangler/src/core/register-commands.ts
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ function createCommandTree() {
// STEP 1: Create tree from flat definitions array

for (const def of COMMAND_DEFINITIONS) {
const node = createNodeFor(def.command, root);
const node = upsertNodeFor(def.command, root);

if (node.definition) {
throw new CommandRegistrationError(
Expand All @@ -100,7 +100,7 @@ function createCommandTree() {
continue;
}

const node = createNodeFor(def.command, root);
const node = upsertNodeFor(def.command, root);

node.definition = {
...real,
Expand Down Expand Up @@ -179,7 +179,7 @@ function walkTreeAndRegister(
}

// #region utils
function createNodeFor(command: Command, root: DefinitionTreeNode) {
function upsertNodeFor(command: Command, root: DefinitionTreeNode) {
const segments = command.split(" ").slice(1); // eg. ["versions", "secret", "put"]

let node = root;
Expand Down

0 comments on commit 67876f5

Please sign in to comment.