Skip to content

Commit

Permalink
refactor: Rename parameter for consistency
Browse files Browse the repository at this point in the history
  • Loading branch information
davidparsson committed Feb 1, 2024
1 parent 5ebe11d commit c405574
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/test_group.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ var { TestNode } = require('./test_node');
class TestGroup extends TestNode {
/**
* @param {import('./factory').Factory} factory
* @param {string} nodeName
* @param {string} elementName
*/
constructor(factory, nodeName) {
super(factory, nodeName);
constructor(factory, elementName) {
super(factory, elementName);
this._children = [];
}

Expand Down
8 changes: 4 additions & 4 deletions src/test_node.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ var _ = require('lodash');
class TestNode {
/**
* @param {import('./factory').Factory} factory
* @param {string} nodeName
* @param {string} elementName
*/
constructor(factory, nodeName) {
constructor(factory, elementName) {
this._factory = factory;
this._nodeName = nodeName;
this._elementName = elementName;
this._attributes = {};
this._properties = [];
}
Expand Down Expand Up @@ -50,7 +50,7 @@ class TestNode {
* @returns {import('xmlbuilder').XMLElement}
*/
createNode(parentElement) {
return parentElement.ele(this._nodeName, this._attributes);
return parentElement.ele(this._elementName, this._attributes);
}

/**
Expand Down

0 comments on commit c405574

Please sign in to comment.