Skip to content

Commit

Permalink
Track telemetry download events for GET requests only
Browse files Browse the repository at this point in the history
Signed-off-by: Kim Tsao <[email protected]>
  • Loading branch information
kim-tsao committed Aug 29, 2022
1 parent e70843d commit 9e3d7ef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index/server/pkg/server/index.go
Original file line number Diff line number Diff line change
Expand Up @@ -171,8 +171,8 @@ func ociServerProxy(c *gin.Context) {
proxy := httputil.NewSingleHostReverseProxy(remote)

// Set up the request to the proxy
// Track event for telemetry
if enableTelemetry {
// Track event for telemetry for GET requests only
if enableTelemetry && c.Request.Method == http.MethodGet {
proxyPath := c.Param("proxyPath")
if proxyPath != "" {
var name string
Expand Down

0 comments on commit 9e3d7ef

Please sign in to comment.