Commit 00a7fc74 authored by Kathleen Brade's avatar Kathleen Brade Committed by Georg Koppen
Browse files

Bug 29445: Enable support for enterprise policies

Enable enterprise policies for all update channels, including
"release" (which Tor Browser uses instead of "esr").
parent c6baddf8
Loading
Loading
Loading
Loading
+2 −11
Original line number Diff line number Diff line
@@ -126,7 +126,7 @@ EnterprisePoliciesManager.prototype = {
      }

      if (policySchema.enterprise_only && !areEnterpriseOnlyPoliciesAllowed()) {
        log.error(`Policy ${policyName} is only allowed on ESR`);
        log.error(`Enterprise policy ${policyName} is not allowed`);
        continue;
      }

@@ -314,10 +314,6 @@ let DisallowedFeatures = {};
 * Checks whether the policies marked as enterprise_only in the
 * schema are allowed to run on this browser.
 *
 * This is meant to only allow policies to run on ESR, but in practice
 * we allow it to run on channels different than release, to allow
 * these policies to be tested on pre-release channels.
 *
 * @returns {Bool} Whether the policy can run.
 */
function areEnterpriseOnlyPoliciesAllowed() {
@@ -328,14 +324,9 @@ function areEnterpriseOnlyPoliciesAllowed() {
    return false;
  }

  if (AppConstants.MOZ_UPDATE_CHANNEL != "release" ||
      Cu.isInAutomation) {
  return true;
}

  return false;
}

/*
 * JSON PROVIDER OF POLICIES
 *