diff --git a/src/main/java/com/cloudbees/jenkins/support/actions/SupportRunAction.java b/src/main/java/com/cloudbees/jenkins/support/actions/SupportRunAction.java index ea8a28265..1909ff700 100644 --- a/src/main/java/com/cloudbees/jenkins/support/actions/SupportRunAction.java +++ b/src/main/java/com/cloudbees/jenkins/support/actions/SupportRunAction.java @@ -1,9 +1,12 @@ package com.cloudbees.jenkins.support.actions; +import com.cloudbees.jenkins.support.filter.ContentFilters; import hudson.Extension; import hudson.model.Action; import hudson.model.Run; import jenkins.model.TransientActionFactory; +import org.kohsuke.accmod.Restricted; +import org.kohsuke.accmod.restrictions.NoExternalUse; import org.kohsuke.stapler.DataBoundConstructor; import edu.umd.cs.findbugs.annotations.NonNull; @@ -30,6 +33,12 @@ protected String getBundleNameQualifier() { return "build"; } + @Restricted(NoExternalUse.class) // stapler + @SuppressWarnings("unused") // used by Stapler + public boolean isAnonymized() { + return ContentFilters.get().isEnabled(); + } + @Extension public static class Factory extends TransientActionFactory { diff --git a/src/main/resources/com/cloudbees/jenkins/support/actions/SupportRunAction/index.jelly b/src/main/resources/com/cloudbees/jenkins/support/actions/SupportRunAction/index.jelly index 67a274eed..5e5b7f5a9 100644 --- a/src/main/resources/com/cloudbees/jenkins/support/actions/SupportRunAction/index.jelly +++ b/src/main/resources/com/cloudbees/jenkins/support/actions/SupportRunAction/index.jelly @@ -39,14 +39,14 @@

Click on Generate Bundle to download the Run information in a zip file

- +

Support bundle anonymization is enabled. View anonymized mappings here, or manage anonymization settings in the global security under Support Bundle Anonymization.

- +

Support bundle anonymization is disabled. This can be enabled in the global security under Support Bundle Anonymization.