8

Add Adapter.set_segments() and use it when refreshig the segment

This makes the internal API a bit more consistent
This commit is contained in:
Michael van Tellingen
2017-05-31 15:14:32 +02:00
parent decfc88efe
commit f2aa8879a9
4 changed files with 17 additions and 13 deletions

View File

@@ -33,7 +33,7 @@ class PersonalisedStructBlock(blocks.StructBlock):
"""
request = context['request']
adapter = get_segment_adapter(request)
user_segments = adapter.get_all_segments()
user_segments = adapter.get_segments()
if value['segment']:
for segment in user_segments: