summaryrefslogtreecommitdiff
path: root/factory/declarations.py
diff options
context:
space:
mode:
Diffstat (limited to 'factory/declarations.py')
-rw-r--r--factory/declarations.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/factory/declarations.py b/factory/declarations.py
index a284930..2122bd2 100644
--- a/factory/declarations.py
+++ b/factory/declarations.py
@@ -320,10 +320,7 @@ class SubFactory(ParameteredAttribute):
override the wrapped factory's defaults
"""
subfactory = self.get_factory()
- if create:
- return subfactory.create(**params)
- else:
- return subfactory.build(**params)
+ return subfactory.simple_generate(create, **params)
class PostGenerationDeclaration(object):