diff --git a/lib/rules/no-use-computed-property-like-method.js b/lib/rules/no-use-computed-property-like-method.js
index 1add2c343..c1c8ca765 100644
--- a/lib/rules/no-use-computed-property-like-method.js
+++ b/lib/rules/no-use-computed-property-like-method.js
@@ -228,6 +228,9 @@ module.exports = {
if (node.parent.type !== 'MemberExpression') return
if (node.parent.property.type !== 'Identifier') return
+ if (node.parent.parent.type !== 'CallExpression') return
+ if (node.parent.parent.callee.type !== 'MemberExpression') return
+ if (!Object.is(node.parent.parent.callee, node.parent)) return
const thisMember = node.parent.property.name
diff --git a/tests/lib/rules/no-use-computed-property-like-method.js b/tests/lib/rules/no-use-computed-property-like-method.js
index b6e5e6958..902f29b19 100644
--- a/tests/lib/rules/no-use-computed-property-like-method.js
+++ b/tests/lib/rules/no-use-computed-property-like-method.js
@@ -418,6 +418,26 @@ tester.run('no-use-computed-property-like-method', rule, {
}
`
+ },
+ {
+ filename: 'test.vue',
+ code: `
+
+ `
}
],
invalid: [
@@ -698,6 +718,50 @@ tester.run('no-use-computed-property-like-method', rule, {
errors: [
'Use this.computedReturnNothing instead of this.computedReturnNothing().'
]
+ },
+ {
+ filename: 'test.vue',
+ code: `
+
+ `,
+ errors: [
+ 'Use this.computedReturnString instead of this.computedReturnString().'
+ ]
+ },
+ {
+ filename: 'test.vue',
+ code: `
+
+ `,
+ errors: [
+ 'Use this.computedReturnArray instead of this.computedReturnArray().',
+ 'Use this.computedReturnArray2 instead of this.computedReturnArray2().'
+ ]
}
]
})