summaryrefslogtreecommitdiff
path: root/factory
diff options
context:
space:
mode:
Diffstat (limited to 'factory')
-rw-r--r--factory/declarations.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/factory/declarations.py b/factory/declarations.py
index 828d8a7..6b53c88 100644
--- a/factory/declarations.py
+++ b/factory/declarations.py
@@ -244,12 +244,10 @@ class SubFactory(OrderedDeclaration):
defaults.update(extra)
defaults['__containers'] = containers
- attrs = self.factory.attributes(create, defaults)
-
if create:
- return self.factory.create(**attrs)
+ return self.factory.create(**defaults)
else:
- return self.factory.build(**attrs)
+ return self.factory.build(**defaults)
class PostGenerationDeclaration(object):