Explorar el Código

Set the validation error when err == nil too

gabrielseibel1 hace 2 años
padre
commit
9ddc1222db
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      pro/license.go

+ 1 - 1
pro/license.go

@@ -51,8 +51,8 @@ func ValidateLicense() (err error) {
 	defer func() {
 		if err != nil {
 			err = fmt.Errorf("%w: %s", errValidation, err.Error())
-			servercfg.ErrLicenseValidation = err
 		}
+		servercfg.ErrLicenseValidation = err
 	}()
 
 	licenseKeyValue := servercfg.GetLicenseKey()