[gnome-shell] perf: Shut up another eslint error



commit 93a461f3f7b3c259dc7b7dcf14b685337b8be3c3
Author: Florian Müllner <fmuellner gnome org>
Date:   Sat Jun 29 15:14:37 2019 +0200

    perf: Shut up another eslint error
    
    The functions here are asynchronous to handle control back to the
    mainloop while waiting for an action to complete, not to run operations
    in parallel. That is, the race condition the rule is protecting against
    isn't an issue here, so disable the error.
    
    https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/627

 js/perf/core.js   | 2 ++
 js/perf/hwtest.js | 1 +
 2 files changed, 3 insertions(+)
---
diff --git a/js/perf/core.js b/js/perf/core.js
index 314d3ecf5..a2af0f9be 100644
--- a/js/perf/core.js
+++ b/js/perf/core.js
@@ -126,9 +126,11 @@ function *run() {
 
     for (let i = 0; i < 2; i++) {
         Scripting.scriptEvent('applicationsShowStart');
+        // eslint-disable-next-line require-atomic-updates
         Main.overview._dash.showAppsButton.checked = true;
         yield Scripting.waitLeisure();
         Scripting.scriptEvent('applicationsShowDone');
+        // eslint-disable-next-line require-atomic-updates
         Main.overview._dash.showAppsButton.checked = false;
         yield Scripting.waitLeisure();
     }
diff --git a/js/perf/hwtest.js b/js/perf/hwtest.js
index 9c3c620fd..fa2456323 100644
--- a/js/perf/hwtest.js
+++ b/js/perf/hwtest.js
@@ -126,6 +126,7 @@ function *run() {
     yield Scripting.sleep(1000);
 
     Scripting.scriptEvent('applicationsShowStart');
+    // eslint-disable-next-line require-atomic-updates
     Main.overview._dash.showAppsButton.checked = true;
 
     yield Scripting.waitLeisure();


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]