From 287fe82d31de8c8d610baa947221f4064c9fc795 Mon Sep 17 00:00:00 2001 From: "James R. Maddison" Date: Wed, 10 Jul 2024 16:09:06 +0100 Subject: [PATCH] Fix --- firedrake/adjoint_utils/blocks/solving.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/firedrake/adjoint_utils/blocks/solving.py b/firedrake/adjoint_utils/blocks/solving.py index d435237990..3790a83860 100644 --- a/firedrake/adjoint_utils/blocks/solving.py +++ b/firedrake/adjoint_utils/blocks/solving.py @@ -332,10 +332,10 @@ def solve_tlm(self): continue tlm_dep = block_variable.tlm_value if isinstance(dep, firedrake.DirichletBC): - if tlm_value is None: + if tlm_dep is None: tlm_bcs.append(dep.reconstruct(g=0)) else: - tlm_bcs.append(tlm_value) + tlm_bcs.append(tlm_dep) elif tlm_dep is not None: if isinstance(dep, firedrake.MeshGeometry): dep = firedrake.SpatialCoordinate(dep)