This commit is contained in:
@@ -2491,4 +2491,11 @@ angular.module('syncthing.core')
|
||||
$scope.config.options.crashReportingEnabled = enabled;
|
||||
$scope.saveConfig();
|
||||
};
|
||||
|
||||
$scope.isUnixAddress = function (address) {
|
||||
return address != null &&
|
||||
(address.startsWith('/') ||
|
||||
address.startsWith('unix://') ||
|
||||
address.startsWith('unixs://'));
|
||||
}
|
||||
});
|
||||
|
||||
@@ -172,6 +172,13 @@
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div ng-if="isUnixAddress(tmpGUI.address)" class="form-group" ng-class="{'has-error': settingsEditor.UnixSocketPermissions.$invalid && settingsEditor.UnixSocketPermissions.$dirty}">
|
||||
<label translate>UNIX Permissions</label>
|
||||
<input id="UnixSocketPermissions" name="UnixSocketPermissions" class="form-control" type="text" ng-model="tmpGUI.unixSocketPermissions" ng-pattern="/^0?[0-7]{0,3}$/" />
|
||||
<p class="help-block" ng-show="settingsEditor.UnixSocketPermissions.$invalid" translate>
|
||||
Enter up to three octal digits.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user