]> git.scottworley.com Git - pinch/commitdiff
Prefer more type-safe NamedTuple over SimpleNamespace
authorScott Worley <scottworley@scottworley.com>
Tue, 16 Jun 2020 08:29:38 +0000 (01:29 -0700)
committerScott Worley <scottworley@scottworley.com>
Thu, 18 Jun 2020 06:15:29 +0000 (23:15 -0700)
pinch.py

index f4fd0b5e9ed0739d2e323da9fad8580473c46ddf..8fe7df16c10958ccaa6c0edfd8c7a834d444faa4 100644 (file)
--- a/pinch.py
+++ b/pinch.py
@@ -34,7 +34,7 @@ from typing import (
 # Use xdg module when it's less painful to have as a dependency
 
 
-class XDG(types.SimpleNamespace):
+class XDG(NamedTuple):
     XDG_CACHE_HOME: str