Skip to content

Commit

Permalink
tiny enhancement of type
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielYang59 committed Nov 25, 2024
1 parent eb7762c commit 5e9a640
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/pymatgen/io/vasp/outputs.py
Original file line number Diff line number Diff line change
Expand Up @@ -2134,7 +2134,7 @@ def __init__(self, filename: PathLike) -> None:
self.final_energy = e0
self.final_energy_wo_entrp = e_wo_entrp
self.final_fr_energy = e_fr_energy
self.data: dict = {}
self.data: dict[str, Any] = {}

# Read "total number of plane waves", NPLWV:
self.read_pattern(
Expand Down Expand Up @@ -2197,7 +2197,7 @@ def __init__(self, filename: PathLike) -> None:

# Check if LEPSILON is True and read piezo data if so
self.read_pattern({"epsilon": r"LEPSILON\s*=\s*T"})
if self.data.get("epsilon", []):
if self.data.get("epsilon", False):
self.lepsilon = True
self.read_lepsilon()
# Only read ionic contribution if DFPT is turned on
Expand All @@ -2208,7 +2208,7 @@ def __init__(self, filename: PathLike) -> None:

# Check if LCALCPOL is True and read polarization data if so
self.read_pattern({"calcpol": r"LCALCPOL\s*=\s*T"})
if self.data.get("calcpol", []):
if self.data.get("calcpol", False):
self.lcalcpol = True
self.read_lcalcpol()
self.read_pseudo_zval()
Expand All @@ -2220,7 +2220,7 @@ def __init__(self, filename: PathLike) -> None:
self.ngf = None
self.sampling_radii: list[float] | None = None
self.read_pattern({"electrostatic": r"average \(electrostatic\) potential at core"})
if self.data.get("electrostatic", []):
if self.data.get("electrostatic", False):
self.read_electrostatic_potential()

self.read_pattern({"nmr_cs": r"LCHIMAG\s*=\s*(T)"})
Expand Down

0 comments on commit 5e9a640

Please sign in to comment.