diff piecrust/baking/baker.py @ 23:923699e816d0

Don't try to get the name of a source that doesn't have one. TODO: clean up code duplication.
author Ludovic Chabant <ludovic@chabant.com>
date Tue, 19 Aug 2014 08:34:16 -0700
parents 617191dec18e
children 65ae19c4e8a3
line wrap: on
line diff
--- a/piecrust/baking/baker.py	Mon Aug 18 23:20:43 2014 -0700
+++ b/piecrust/baking/baker.py	Tue Aug 19 08:34:16 2014 -0700
@@ -165,8 +165,7 @@
 
             has_more_subs = False
             if ctx.used_pagination is not None:
-                cur_record_entry.used_source_names.add(
-                        ctx.used_pagination._source.name)
+                cur_record_entry.addUsedSource(ctx.used_pagination._source)
                 if ctx.used_pagination.has_more:
                     cur_sub += 1
                     has_more_subs = True