diff --git a/CHANGELOG.md b/CHANGELOG.md index 25e3c6ce..c1251857 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,8 @@ 1. [](#improved) * Force height of Flex pages admin to fit available space +1. [](#bugfix) + * Fixed error when checking missing log file [#2088](https://github.com/getgrav/grav-plugin-admin/issues/2088) # v1.10.6 ## 02/23/2021 @@ -13,7 +15,7 @@ * Flex pages admin better uses available space [#2075](https://github.com/getgrav/grav/issues/2075) 1. [](#bugfix) * Regression: Fixed enabling/disabling plugin or theme corrupting configuration - * Fixed unnecessary closing bracket cuasing JS error [#2079](https://github.com/getgrav/grav-plugin-admin/issues/2079) + * Fixed unnecessary closing bracket causing JS error [#2079](https://github.com/getgrav/grav-plugin-admin/issues/2079) * Fixed wrong language in Admin Tools [#2077](https://github.com/getgrav/grav-plugin-admin/issues/2077) # v1.10.5 diff --git a/themes/grav/templates/partials/tools-logs.html.twig b/themes/grav/templates/partials/tools-logs.html.twig index 1bef7325..56bee777 100644 --- a/themes/grav/templates/partials/tools-logs.html.twig +++ b/themes/grav/templates/partials/tools-logs.html.twig @@ -19,7 +19,7 @@ {% set verbose = grav.uri.query('verbose') == 'true' ? true : false %} {% set lines = grav.uri.query('lines') ?: 20 %} {% set logfile = grav.locator.findResource("log://" ~ file) %} - {% set logs = logviewer.objectTail(logfile, lines|int, false) %} + {% set logs = logfile ? logviewer.objectTail(logfile, lines|int, false) : [] %} {% set log_files = admin.getLogFiles() %} {% set title = log_files[file] %}