1
0
mirror of https://gitee.com/sui-feng-cb/AzurLaneAutoScript1 synced 2026-03-12 05:08:19 +08:00

Merge pull request #1823 from SaiCateDoan/maa

Opt: Optimized logic of MaaMaterial
This commit is contained in:
LmeSzinc
2022-11-06 00:36:49 +08:00
committed by GitHub
12 changed files with 253 additions and 53 deletions

View File

@@ -155,7 +155,9 @@ class ConfigGenerator:
# But allow `Interval` to be different
old_value = old.get('value', None) if isinstance(old, dict) else old
value = old.get('value', None) if isinstance(value, dict) else value
if type(value) != type(old_value) and path[2] not in ['SuccessInterval', 'FailureInterval']:
if type(value) != type(old_value) \
and old_value is not None \
and path[2] not in ['SuccessInterval', 'FailureInterval']:
print(
f'`{value}` ({type(value)}) and `{".".join(path)}` ({type(old_value)}) are in different types')
return False