Fix key and deleteKey being ignored when creating a snapshot with external=true set (#33686)

* Update dashboard_snapshot.go

This is to address: https://github.com/grafana/grafana/issues/33665

The key and deleteKey fields are not honoured when creating a snapshot with external:true set

* removed whitespace
This commit is contained in:
wengelbrecht-grafana 2021-05-13 23:39:43 +01:00 committed by GitHub
parent 917a9ace57
commit 2fc9c6ca58
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -44,6 +44,8 @@ func createExternalDashboardSnapshot(cmd models.CreateDashboardSnapshotCommand)
"name": cmd.Name,
"expires": cmd.Expires,
"dashboard": cmd.Dashboard,
"key": cmd.Key,
"deleteKey": cmd.DeleteKey,
}
messageBytes, err := simplejson.NewFromAny(message).Encode()