Remove unnecessary comments

This commit is contained in:
2025-04-29 02:45:56 -05:00
parent b2ead348e5
commit 7dbde25bcf
2 changed files with 5 additions and 23 deletions

View File

@ -6,29 +6,15 @@ import (
"github.com/rs/cors"
)
// CORSConfig defines the configuration options for CORS middleware
type CORSConfig struct {
// AllowedOrigins defines the origins that are allowed to access the resource
AllowedOrigins []string
// AllowedMethods defines the HTTP methods that are allowed
AllowedMethods []string
// AllowedHeaders defines the headers that are allowed in requests
AllowedHeaders []string
// ExposedHeaders defines the headers that can be read by the browser
ExposedHeaders []string
// AllowCredentials defines whether cookies, HTTP authentication and client SSL
// certificates can be transmitted in cross-origin requests
AllowedOrigins []string
AllowedMethods []string
AllowedHeaders []string
ExposedHeaders []string
AllowCredentials bool
// MaxAge defines how long (in seconds) the results of a preflight request can be cached
MaxAge int
MaxAge int
}
// DefaultCORSConfig returns a default configuration for CORS middleware
func DefaultCORSConfig() CORSConfig {
return CORSConfig{
AllowedOrigins: []string{},