fix: don't fail a migration if there is no filter saved
This commit is contained in:
parent
d709db4e18
commit
10ded56f66
1 changed files with 5 additions and 1 deletions
|
@ -40,7 +40,11 @@ func init() {
|
||||||
|
|
||||||
for _, f := range filters {
|
for _, f := range filters {
|
||||||
filter := map[string]interface{}{}
|
filter := map[string]interface{}{}
|
||||||
err = json.Unmarshal([]byte(f["filters"].(string)), &filter)
|
filterJSON, is := f["filters"].(string)
|
||||||
|
if !is {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
err = json.Unmarshal([]byte(filterJSON), &filter)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue