Skip to content

Commit b6cb5c9

Browse files
update type and name of propName argument
1 parent 5615839 commit b6cb5c9

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

lib/internal/repl/completion.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -776,21 +776,21 @@ function includesProxiesOrGetters(expr, exprStr, evalFn, ctx, callback) {
776776
* whether its value is a proxy, to ensure that is the property does have a getter we don't end up
777777
* triggering it when checking its value
778778
* @param {any} obj The target object
779-
* @param {string} propName The target property name
779+
* @param {string | number | bigint | boolean | RegExp} prop The target property
780780
* @param {(includes: boolean) => void} cb Callback that will be called with the result of the operation
781781
* @returns {void}
782782
*/
783-
function propHasGetterOrIsProxy(obj, propName, cb) {
783+
function propHasGetterOrIsProxy(obj, prop, cb) {
784784
const propDescriptor = ObjectGetOwnPropertyDescriptor(
785785
obj,
786-
propName,
786+
prop,
787787
);
788788
const propHasGetter = typeof propDescriptor?.get === 'function';
789789
if (propHasGetter) {
790790
return cb(true);
791791
}
792792

793-
if (isProxy(obj[propName])) {
793+
if (isProxy(obj[prop])) {
794794
return cb(true);
795795
}
796796

0 commit comments

Comments
 (0)