diff --git a/src/scheme/AcousticSolver.cpp b/src/scheme/AcousticSolver.cpp
index 5b4d9cb57cdea7a374b68447fc7a79ba81562e84..e5171badb11fa509a020025ad38e7e7bbd96281d 100644
--- a/src/scheme/AcousticSolver.cpp
+++ b/src/scheme/AcousticSolver.cpp
@@ -241,14 +241,6 @@ class AcousticSolverHandler::AcousticSolver final : public AcousticSolverHandler
   {
     BoundaryConditionList bc_list;
 
-    constexpr ItemType FaceType = [] {
-      if constexpr (Dimension > 1) {
-        return ItemType::face;
-      } else {
-        return ItemType::node;
-      }
-    }();
-
     for (const auto& bc_descriptor : bc_descriptor_list) {
       bool is_valid_boundary_condition = true;
 
@@ -288,6 +280,14 @@ class AcousticSolverHandler::AcousticSolver final : public AcousticSolverHandler
 
             bc_list.emplace_back(PressureBoundaryCondition{mesh_node_boundary, node_values});
           } else {
+            constexpr ItemType FaceType = [] {
+              if constexpr (Dimension > 1) {
+                return ItemType::face;
+              } else {
+                return ItemType::node;
+              }
+            }();
+
             MeshFaceBoundary<Dimension> mesh_face_boundary =
               getMeshFaceBoundary(mesh, bc_descriptor->boundaryDescriptor());