Bug fix for bitmath types in saved config
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
""" version info """
|
||||
|
||||
__version__ = "0.46.5"
|
||||
__version__ = "0.46.6"
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
""" ConfigOptions class to load/save config settings for osxphotos CLI """
|
||||
import bitmath
|
||||
import toml
|
||||
|
||||
__all__ = [
|
||||
@@ -178,6 +179,10 @@ class ConfigOptions:
|
||||
data = {}
|
||||
for attr in sorted(self._attrs.keys()):
|
||||
val = getattr(self, attr)
|
||||
|
||||
if isinstance(val, bitmath.Bitmath):
|
||||
val = int(val.to_Byte())
|
||||
|
||||
if val in [False, ()]:
|
||||
val = None
|
||||
else:
|
||||
|
||||
Reference in New Issue
Block a user