Skip to content

Commit 333618d

Browse files
Security-Policy should not run on --local (#1825)
Co-authored-by: Azeem Shaikh <azeems@google.com>
1 parent 4df16f3 commit 333618d

File tree

3 files changed

+0
-10
lines changed

3 files changed

+0
-10
lines changed

checks/raw/security_policy.go

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,11 +41,6 @@ func SecurityPolicy(c *checker.CheckRequest) (checker.SecurityPolicyData, error)
4141
}
4242

4343
// Check if present in parent org.
44-
parentOrg := c.Repo.Org()
45-
if parentOrg == nil {
46-
return checker.SecurityPolicyData{}, nil
47-
}
48-
4944
// https#://docs.github.com/en/github/building-a-strong-community/creating-a-default-community-health-file.
5045
// TODO(1491): Make this non-GitHub specific.
5146
logger := log.NewLogger(log.InfoLevel)

checks/raw/security_policy_test.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,10 +99,6 @@ func TestSecurityPolicy(t *testing.T) {
9999
"doc/security.rst",
100100
},
101101
},
102-
{
103-
name: "early return if org is null",
104-
files: []string{},
105-
},
106102
}
107103
for _, tt := range tests {
108104
tt := tt

checks/security_policy.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ const CheckSecurityPolicy = "Security-Policy"
2727
//nolint:gochecknoinits
2828
func init() {
2929
supportedRequestTypes := []checker.RequestType{
30-
checker.FileBased,
3130
checker.CommitBased,
3231
}
3332
if err := registerCheck(CheckSecurityPolicy, SecurityPolicy, supportedRequestTypes); err != nil {

0 commit comments

Comments
 (0)