]> git.proxmox.com Git - pve-eslint.git/blobdiff - eslint/lib/rules/no-useless-return.js
import 8.41.0 source
[pve-eslint.git] / eslint / lib / rules / no-useless-return.js
index be8d4dfd3a52b4df4611d2d837cf0b497ae35396..db1ccae97393829d0049d5430ec5b8acdc3e04f1 100644 (file)
@@ -69,7 +69,7 @@ module.exports = {
         docs: {
             description: "Disallow redundant return statements",
             recommended: false,
-            url: "https://eslint.org/docs/rules/no-useless-return"
+            url: "https://eslint.org/docs/latest/rules/no-useless-return"
         },
 
         fixable: "code",
@@ -83,7 +83,7 @@ module.exports = {
     create(context) {
         const segmentInfoMap = new WeakMap();
         const usedUnreachableSegments = new WeakSet();
-        const sourceCode = context.getSourceCode();
+        const sourceCode = context.sourceCode;
         let scopeInfo = null;
 
         /**
@@ -197,7 +197,7 @@ module.exports = {
 
         return {
 
-            // Makes and pushs a new scope information.
+            // Makes and pushes a new scope information.
             onCodePathStart(codePath) {
                 scopeInfo = {
                     upper: scopeInfo,