config pb

This commit is contained in:
mr 2024-07-18 16:14:39 +02:00
parent e3a7703bc5
commit 8eb88dcd82

12
conf.go
View File

@ -9,16 +9,16 @@ import "sync"
// ===================================================
type Config struct {
mongoUrl string
mongoDatabase string
MongoUrl string
MongoDatabase string
}
func (c Config) GetUrl() string {
return c.mongoUrl
return c.MongoUrl
}
func (c Config) GetDatabase() string {
return c.mongoDatabase
return c.MongoDatabase
}
var instance *Config
@ -33,8 +33,8 @@ func GetConfig() *Config {
func SetConfig(url string, database string) *Config {
instance = &Config{
mongoUrl: url,
mongoDatabase: database,
MongoUrl: url,
MongoDatabase: database,
}
return instance
}