diff options
author | Martin Whitaker <mageia@martin-whitaker.me.uk> | 2018-11-14 00:33:12 +0000 |
---|---|---|
committer | Martin Whitaker <mageia@martin-whitaker.me.uk> | 2018-11-14 00:33:12 +0000 |
commit | c1592abdd07d7db513646c3bf75d1808cad0d638 (patch) | |
tree | 19ce9e573313c6983689c4ce8e27289ac823da9b | |
parent | 76fc2d1aa07e263e19e38194cb58e3725b41e179 (diff) | |
download | qarepo-c1592abdd07d7db513646c3bf75d1808cad0d638.tar qarepo-c1592abdd07d7db513646c3bf75d1808cad0d638.tar.gz qarepo-c1592abdd07d7db513646c3bf75d1808cad0d638.tar.bz2 qarepo-c1592abdd07d7db513646c3bf75d1808cad0d638.tar.xz qarepo-c1592abdd07d7db513646c3bf75d1808cad0d638.zip |
Fix bug in polkit rules.
-rw-r--r-- | org.mageia.qarepo-helper.rules | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/org.mageia.qarepo-helper.rules b/org.mageia.qarepo-helper.rules index 8408234..6a9e964 100644 --- a/org.mageia.qarepo-helper.rules +++ b/org.mageia.qarepo-helper.rules @@ -1,10 +1,9 @@ polkit.addRule(function(action, subject) { - if (action.id == "org.mageia.qarepo-helper.pkexec.run" && - subject.local && subject.active && - subject.isInGroup("qarepo")) { - return polkit.Result.YES; - } else { - return polkit.Result.AUTH_ADMIN_KEEP; + if (action.id == "org.mageia.qarepo-helper.pkexec.run") { + if (subject.local && subject.active && subject.isInGroup("qarepo")) { + return polkit.Result.YES; + } else { + return polkit.Result.AUTH_ADMIN_KEEP; + } } }); - |