2012-08-22 14:15:04 +01:00
|
|
|
polkit.addRule(function(action, subject) {
|
2012-11-16 19:59:14 +01:00
|
|
|
if ((action.id == "org.freedesktop.hostname1.set-static-hostname" ||
|
|
|
|
action.id == "org.freedesktop.hostname1.set-hostname") &&
|
2012-08-22 14:15:04 +01:00
|
|
|
subject.local &&
|
|
|
|
subject.active &&
|
|
|
|
subject.isInGroup ("wheel")) {
|
|
|
|
return polkit.Result.YES;
|
|
|
|
}
|
|
|
|
});
|