You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: statscfg.go
    path of file: ./repos/tegola/vendor/github.com/SAP/go-hdb/driver
    
    the code of the file until where you have to start completion: package driver

import (
	_ "embed" // embed stats configuration
	"encoding/json"
	"fmt"

	"golang.org/x/exp/slices"
)

//go:embed statscfg.json
var sta
    
func loadStatsCfg() error {

	if err := json.Unmarshal(statsCfgRaw, &statsCfg); err != nil {
		return fmt.Errorf("invalid statscfg.json file: %s", err)
	}

	if len(statsCfg.SQLTimeTexts) != int(numSQLTime) {
		return fmt.Errorf("invalid number of statscfg.json sqlTimeTexts %d - expected %d", len(statsCfg.SQLTimeTexts), numSQLTime)
	}
	if len(statsCfg.TimeUpperBounds) == 0 {
		return fmt.Errorf("number of statscfg.json timeUpperBounds needs to be greater than %d", 0)
	}

	// sort and dedup timeBuckets
	slices.Sort(statsCfg.TimeUpperBounds)
	statsCfg.TimeUpperBounds = slices.Compact(statsCfg.TimeUpperBounds)

	return nil
}