summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--service/env/service.go9
1 files changed, 7 insertions, 2 deletions
diff --git a/service/env/service.go b/service/env/service.go
index 9fb110c3..0822d55a 100644
--- a/service/env/service.go
+++ b/service/env/service.go
@@ -10,8 +10,13 @@ type Service struct {
}
// NewService creates new env service instance for given rr version.
-func NewService(version string) *Service {
- return &Service{values: map[string]string{"rr": version}}
+func NewService(defaults map[string]string) *Service {
+ s := &Service{values: defaults}
+ if s.values == nil {
+ s.values = make(map[string]string)
+ }
+
+ return s
}
// Init must return configure svc and return true if svc hasStatus enabled. Must return error in case of