Skip to content

Commit

Permalink
fix: allow removing default configurations by setting to empty string (
Browse files Browse the repository at this point in the history
  • Loading branch information
razonyang committed Feb 8, 2024
1 parent 52150e2 commit 92df633
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion layouts/partials/decap-cms/functions/config.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,12 @@
{{- range $keys -}}
{{- $key := . -}}
{{- if isset $params $key -}}
{{- $config.Set $key (index $params $key) -}}
{{- $val := index $params $key }}
{{/* Ignore empty value. */}}
{{- if eq $val "" }}
{{- continue }}
{{- end }}
{{- $config.Set $key $val -}}
{{- end -}}
{{- end -}}
{{- $definitions := partial "decap-cms/functions/definitions" (default dict (index $params "_configs")) }}
Expand Down

0 comments on commit 92df633

Please sign in to comment.