From 0777e61e0feca9b80cf2d2081b4ed70da28cb60e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?V=C3=ADt=20Novotn=C3=BD?= <witiko@mail.muni.cz>
Date: Sun, 21 Feb 2021 12:38:37 +0100
Subject: [PATCH] Hotfix biblatex v3.15a

See https://github.com/plk/biblatex/issues/1058 and
https://tex.stackexchange.com/a/581469/70941. The hotfix should be
reverted after BibLaTeX v3.17.
---
 fithesis.dtx      | 12 +++++++-----
 style/mu/base.dtx |  4 ++++
 2 files changed, 11 insertions(+), 5 deletions(-)

diff --git a/fithesis.dtx b/fithesis.dtx
index 3cafacd..dcbfcb0 100644
--- a/fithesis.dtx
+++ b/fithesis.dtx
@@ -1527,15 +1527,17 @@
         \thesis@requireLocale{\thesis@locale}
       \fi
 %    \end{macrocode}
-% Coerce LuaTeX into defining |\l@|\textit{locale} for
+% Coerce Lua\TeX{} into defining |\l@|\textit{locale} for
 % \textit{locale}s with known hyphenation patterns, unless
-% \textsf{babel} has been loaded. In that case
-% |\l@|\textit{locale} has already been defined.
+% \textsf{babel} or \textsf{polyglossia} have been loaded.
+% In that case, |\l@|\textit{locale} has already been defined.
+% \changes{v1.0.0}{2020/02/21}{Only load \textsf{babel} in
+%   Lua\TeX{} if \textsf{polyglossia} has not been loaded yet.}
 %    \begin{macrocode}
     \ifluatex
       \ltx@ifpackageloaded{babel}{}{
-        % See <article.gmane.org/gmane.comp.tex.luatex.user/5680>
-        \RequirePackage[base]{babel}}
+        \ltx@ifpackageloaded{polyglossia}{}{
+          \thesis@require{babel}}}
     \fi
 %    \end{macrocode}
 % Fix the value of the |\ifthesis@english| macro.
diff --git a/style/mu/base.dtx b/style/mu/base.dtx
index 5189807..12a29c5 100644
--- a/style/mu/base.dtx
+++ b/style/mu/base.dtx
@@ -432,6 +432,10 @@
       \thesis@bibliography@setup{
         style = iso-numeric,
         sorting = none}
+      % FIXME: This is a hotfix for biblatex.
+      % It should be removed after v3.17 has been released.
+      % See https://tex.stackexchange.com/a/581469/70941.
+      \thesis@require{expl3}
       \thesis@require[
         backend=biber,
         style=\thesis@bibliography@style,
-- 
GitLab