Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2015-05-31 08:56:22 +0300
committerCampbell Barton <ideasman42@gmail.com>2015-05-31 08:58:58 +0300
commitf5a471ef865dcbd0807c7b4ff71825d288b66453 (patch)
treebb48e339e23127f418a170f7fafc2846f1f0cb1e /release/scripts/modules/addon_utils.py
parent67bebc42f4a789487583b7e2c7f1174910ab67f9 (diff)
Python: avoid mutable default param values
D1328 by @yedpodtrzitko
Diffstat (limited to 'release/scripts/modules/addon_utils.py')
-rw-r--r--release/scripts/modules/addon_utils.py28
1 files changed, 15 insertions, 13 deletions
diff --git a/release/scripts/modules/addon_utils.py b/release/scripts/modules/addon_utils.py
index 8c86f31022c..11aeebb8a43 100644
--- a/release/scripts/modules/addon_utils.py
+++ b/release/scripts/modules/addon_utils.py
@@ -416,19 +416,21 @@ def reset_all(reload_scripts=False):
disable(mod_name)
-def module_bl_info(mod, info_basis={"name": "",
- "author": "",
- "version": (),
- "blender": (),
- "location": "",
- "description": "",
- "wiki_url": "",
- "support": 'COMMUNITY',
- "category": "",
- "warning": "",
- "show_expanded": False,
- }
- ):
+def module_bl_info(mod, info_basis=None):
+ if info_basis is None:
+ info_basis = {
+ "name": "",
+ "author": "",
+ "version": (),
+ "blender": (),
+ "location": "",
+ "description": "",
+ "wiki_url": "",
+ "support": 'COMMUNITY',
+ "category": "",
+ "warning": "",
+ "show_expanded": False,
+ }
addon_info = getattr(mod, "bl_info", {})