From b8dfececc086f2f48ebc3847ee32a2519aea3ae9 Mon Sep 17 00:00:00 2001
From: DennisGlaeser <dennis.glaeser@iws.uni-stuttgart.de>
Date: Tue, 30 Jan 2018 16:49:58 +0100
Subject: [PATCH] [mpfa][fluxcachefiller] be compatible with the tracer model

---
 .../cellcentered/mpfa/fluxvariablescachefiller.hh              | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/dumux/discretization/cellcentered/mpfa/fluxvariablescachefiller.hh b/dumux/discretization/cellcentered/mpfa/fluxvariablescachefiller.hh
index b0ced7e512..8b0863abf7 100644
--- a/dumux/discretization/cellcentered/mpfa/fluxvariablescachefiller.hh
+++ b/dumux/discretization/cellcentered/mpfa/fluxvariablescachefiller.hh
@@ -315,7 +315,8 @@ private:
         {
             for (unsigned int compIdx = 0; compIdx < numComponents; ++compIdx)
             {
-                if (phaseIdx == compIdx)
+                using FluidSystem = typename GET_PROP_TYPE(TypeTag, FluidSystem);
+                if (compIdx == FluidSystem::getMainComponent(phaseIdx))
                     continue;
 
                 // fill data in the handle
-- 
GitLab