Add condition to disable edit post on single pages (#1143)

editPost:
    disabled: true

---------

Co-authored-by: Aditya Telange <21258296+adityatelange@users.noreply.github.com>
This commit is contained in:
Douglas Tofoli 2023-04-01 16:04:56 -03:00 committed by GitHub
parent 5d2c036624
commit 031e2ba57e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -1,4 +1,4 @@
{{- if or .Params.editPost.URL site.Params.editPost.URL -}}
{{- if and (or .Params.editPost.URL site.Params.editPost.URL) (not (.Param "editPost.disabled")) -}}
{{- $fileUrlPath := path.Join .File.Path }}
{{- if or .Params.author site.Params.author (.Param "ShowReadingTime") (not .Date.IsZero) .IsTranslated }}&nbsp;|&nbsp;{{- end -}}