Provisioning: Ignore dashboard change warning after save (#115401)
This commit is contained in:
@@ -277,6 +277,16 @@ func (r *DualReadWriter) createOrUpdate(ctx context.Context, create bool, opts D
|
||||
// FIXME: to make sure if behaves in the same way as in sync, we should
|
||||
// we should refactor the code to use the same function.
|
||||
if r.shouldUpdateGrafanaDB(opts, parsed) {
|
||||
// HACK: Get the has from repository -- this will avoid an additional RV increment
|
||||
// we should change the signature of Create and Update to return FileInfo instead
|
||||
info, _ = r.repo.Read(ctx, opts.Path, opts.Ref)
|
||||
if info != nil {
|
||||
parsed.Meta.SetSourceProperties(utils.SourceProperties{
|
||||
Path: opts.Path,
|
||||
Checksum: info.Hash,
|
||||
})
|
||||
}
|
||||
|
||||
if _, err := r.folders.EnsureFolderPathExist(ctx, opts.Path); err != nil {
|
||||
return nil, fmt.Errorf("ensure folder path exists: %w", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user