We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 09cd2a0 commit d2caf65Copy full SHA for d2caf65
csp_collector.go
@@ -2,7 +2,6 @@ package main
2
3
import (
4
"encoding/json"
5
- "errors"
6
"fmt"
7
"log"
8
"net/http"
@@ -86,7 +85,7 @@ func validateViolation(r CSPReport) error {
86
85
87
for _, value := range ignoredBlockedURIs {
88
if strings.HasPrefix(r.Body.BlockedURI, value) == true {
89
- err := errors.New(fmt.Sprintf("Blocked URI ('%s') is an invalid resource.", value))
+ err := fmt.Errorf("Blocked URI ('%s') is an invalid resource.", value)
90
return err
91
}
92
0 commit comments