From b3ebff7b59e3f0fe1981791b83d6a08dab3b8a3a Mon Sep 17 00:00:00 2001
From: Matiss Janis Aboltins <matiss@mja.lv>
Date: Mon, 2 Jan 2023 19:41:20 +0000
Subject: [PATCH] Allow underscore

---
 .eslintrc.js                                            | 7 +++++++
 packages/desktop-client/src/components/Notifications.js | 2 +-
 2 files changed, 8 insertions(+), 1 deletion(-)

diff --git a/.eslintrc.js b/.eslintrc.js
index 4597913cd..03eb2d0f4 100644
--- a/.eslintrc.js
+++ b/.eslintrc.js
@@ -3,6 +3,13 @@ module.exports = {
   extends: ['react-app'],
   rules: {
     'prettier/prettier': 'error',
+    'no-unused-vars': [
+      'warn',
+      {
+        argsIgnorePattern: '.*', // to keep backwards-compatibility; TODO: consider removing this too
+        varsIgnorePattern: '^_'
+      }
+    ],
     'no-loop-func': 'off',
     'no-restricted-globals': 'off',
 
diff --git a/packages/desktop-client/src/components/Notifications.js b/packages/desktop-client/src/components/Notifications.js
index 333570b0a..43d6b60c5 100644
--- a/packages/desktop-client/src/components/Notifications.js
+++ b/packages/desktop-client/src/components/Notifications.js
@@ -27,7 +27,7 @@ function compileMessage(message, actions, setLoading, onRemove) {
             {parts.map((part, idx) => {
               let match = part.match(/\[([^\]]*)\]\(([^)]*)\)/);
               if (match) {
-                let [, text, href] = match;
+                let [_, text, href] = match;
 
                 if (href[0] === '#') {
                   let actionName = href.slice(1);
-- 
GitLab