We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6da7342 commit 9f411edCopy full SHA for 9f411ed
lib/rules/no-restricted-call-after-await.js
@@ -115,13 +115,6 @@ module.exports = {
115
return allLocalImports
116
}
117
118
- function getCwd() {
119
- if (context.cwd) {
120
- return context.cwd
121
- }
122
- return path.resolve('')
123
124
-
125
/**
126
* @param {string} moduleName
127
* @param {Program} ast
@@ -131,7 +124,7 @@ module.exports = {
131
/** @type {string} */
132
let modulePath
133
if (moduleName.startsWith('.')) {
134
- modulePath = safeRequireResolve(path.join(getCwd(), moduleName))
+ modulePath = safeRequireResolve(path.join(context.cwd, moduleName))
135
128
} else if (path.isAbsolute(moduleName)) {
136
129
modulePath = safeRequireResolve(moduleName)
137
130
} else {
0 commit comments