diff --git a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C index 89223ebb73..1e23871210 100644 --- a/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C +++ b/src/OpenFOAM/db/functionObjects/regionFunctionObject/regionFunctionObjectTemplates.C @@ -59,7 +59,7 @@ bool Foam::functionObjects::regionFunctionObject::store if (cacheable && fieldName == tfield().name()) { WarningInFunction - << "Cannot store cache-able field with the named used in the cache." + << "Cannot store cache-able field with the name used in the cache." << nl << " Either choose a different name or cache the field" << " and use the 'writeObjects' functionObject." diff --git a/src/functionObjects/field/grad/gradTemplates.C b/src/functionObjects/field/grad/gradTemplates.C index fb505bb8b6..d1ad033526 100644 --- a/src/functionObjects/field/grad/gradTemplates.C +++ b/src/functionObjects/field/grad/gradTemplates.C @@ -39,7 +39,7 @@ bool Foam::functionObjects::grad::calcGrad() ( resultName_, fvc::grad(lookupObject(fieldName_)), - true + mesh_.changing() && mesh_.cache(resultName_) ); } else if (foundObject(fieldName_)) @@ -48,7 +48,7 @@ bool Foam::functionObjects::grad::calcGrad() ( resultName_, fvc::grad(lookupObject(fieldName_)), - true + mesh_.changing() && mesh_.cache(resultName_) ); } else