Fix broken setting value provisioning due to missing defaults
This commit is contained in:
@@ -2,6 +2,7 @@ package envoy
|
||||
|
||||
import (
|
||||
"context"
|
||||
"time"
|
||||
|
||||
"github.com/cortezaproject/corteza/server/pkg/envoyx"
|
||||
"github.com/cortezaproject/corteza/server/store"
|
||||
@@ -29,6 +30,10 @@ func (e StoreEncoder) prepareSetting(ctx context.Context, p envoyx.EncodeParams,
|
||||
|
||||
// @todo merge conflicts if we do existing assertion
|
||||
|
||||
if res.UpdatedAt.IsZero() {
|
||||
res.UpdatedAt = time.Now()
|
||||
}
|
||||
|
||||
n.Resource = res
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user