package config

import (
	"os"
	"sync"
)

// Config holds application configuration.
type Config struct {
	Settings map[string]string
}

var instance *Config
var once sync.Once

// Get returns the application configuration.
func Get() *Config {
	once.Do(func() {
		instance = &Config{
			Settings: map[string]string{"env": os.Getenv("APP_ENV")},
		}
	})
	return instance
}
