Skip to content

Commit 81bd9be

Browse files
fix(codemod): do not mark the buildMessage method as private (#5546)
* fix(codemod): do not mark the `buildMessage` method as private It might fail because of the lack of support. * chore(codemod): add missing `filePath` parameter to the docblock
1 parent 6fb0807 commit 81bd9be

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

packages/codemods/src/v5/remove-overloads/utils/unknown-usage-error.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
class UnknownUsageError extends Error {
22
/**
33
* @param {import('jscodeshift').CallExpression} callExpression
4+
* @param {string} filePath
45
*/
56
constructor(callExpression, filePath) {
67
super('')
7-
this.message = this.#buildMessage(callExpression, filePath)
8+
this.message = this.buildMessage(callExpression, filePath)
89
this.name = 'UnknownUsageError'
910
}
1011

@@ -14,7 +15,7 @@ class UnknownUsageError extends Error {
1415
* @param {string} filePath
1516
* @returns {string}
1617
*/
17-
#buildMessage(callExpression, filePath) {
18+
buildMessage(callExpression, filePath) {
1819
const location = callExpression.callee.loc
1920
const start = location.start.line
2021
const end = location.end.line

0 commit comments

Comments
 (0)