chore: use Go 1.26 (#26786)

This commit is contained in:
andig 2026-02-12 15:56:06 +01:00 • committed by GitHub
parent 88ecd6f152
commit 0ee6d787e1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
33 changed files with 96 additions and 122 deletions

View file

@ -98,7 +98,7 @@ func nameValid(name string) error {
func loadConfigFile(conf *globalconfig.All, checkDB bool) error {
if err := viper.ReadInConfig(); err != nil {
if !errors.As(err, &vpr.ConfigFileNotFoundError{}) {
if _, ok := errors.AsType[vpr.ConfigFileNotFoundError](err); !ok {
return fmt.Errorf("failed reading config file: %w", err)
}
}
@ -390,7 +390,7 @@ func vehicleInstance(cc config.Named) (api.Vehicle, error) {
}
if err != nil {
if ce := new(util.ConfigError); errors.As(err, &ce) {
if _, ok := errors.AsType[*util.ConfigError](err); ok {
return nil, err
}
@ -856,7 +856,7 @@ func tariffInstance(name string, conf config.Typed) (api.Tariff, error) {
instance, err := tariff.NewFromConfig(ctx, conf.Type, props)
if err != nil {
if ce := new(util.ConfigError); errors.As(err, &ce) {
if _, ok := errors.AsType[*util.ConfigError](err); ok {
return nil, err
}