Reverting unnecessary DLB change by HR

This commit is contained in:
Hrvoje Jasak 2019-04-30 15:43:38 +01:00
parent b1e3690002
commit e63cc43dfa

View file

@ -70,12 +70,7 @@ Foam::fvSchemes::fvSchemes(const objectRegistry& obr)
"fvSchemes", "fvSchemes",
obr.time().system(), obr.time().system(),
obr, obr,
( IOobject::READ_IF_PRESENT_IF_MODIFIED, // Allow default dictionary creation
obr.readOpt() == IOobject::MUST_READ
|| obr.readOpt() == IOobject::READ_IF_PRESENT
? IOobject::MUST_READ_IF_MODIFIED
: obr.readOpt()
),
IOobject::NO_WRITE IOobject::NO_WRITE
) )
), ),
@ -173,17 +168,21 @@ Foam::fvSchemes::fvSchemes(const objectRegistry& obr)
fluxRequired_(), // Do not read flux required option fluxRequired_(), // Do not read flux required option
defaultFluxRequired_(false) defaultFluxRequired_(false)
{ {
// HR 21.12.18 : Writing a default fvSchemes is not useful in PLB. Please if (!headerOk())
// specify MUST_READ on obr if you need this.
if
(
readOpt() == IOobject::MUST_READ
|| readOpt() == IOobject::MUST_READ_IF_MODIFIED
|| (readOpt() == IOobject::READ_IF_PRESENT && headerOk())
)
{ {
read(); if (debug)
{
InfoIn
(
"fvSchemes::fvSchemes(const objectRegistry& obr)"
) << "fvSchemes dictionary not found. Creating default."
<< endl;
}
regIOobject::write();
} }
read();
} }