Commit 96ec7cbc authored by Henk Verlinde's avatar Henk Verlinde
Browse files

ux: add error handling image not found

parent f6d3a754
Loading
Loading
Loading
Loading
+25 −21
Original line number Diff line number Diff line
{{ $image := .Page.Resources.GetMatch .Destination -}}
{{ with $image -}}
  {{ $lqip := $image.Resize site.Params.lqipWidth -}}

  {{ $imgSrc := "" -}}
@@ -25,3 +26,6 @@
  {{ else -}}
    <img class="img-fluid lazyload blur-up" src="{{ $lqip.Permalink }}" data-src="{{ $image.Permalink }}" width="{{ $image.Width }}" height="{{ $image.Height }}" alt="{{ $.Text }}">
  {{ end -}}
{{ else -}}
  {{ erroridf "image-not-found" "Image not found" -}}
{{ end -}}
 No newline at end of file