year is no longer special case

This commit is contained in:
j 2010-07-14 00:22:36 +02:00
parent cbf25a6f6f
commit 4b7be5402a

View file

@ -212,9 +212,6 @@ Positions
elif 'range' in data: elif 'range' in data:
qs = qs[query['range'][0]:query['range'][1]] qs = qs[query['range'][0]:query['range'][1]]
if name == 'year':
response['data']['items'] = [{'name': i.year, 'items': i.movies} for i in qs]
else:
response['data']['items'] = [{'name': i[name], 'items': i[items]} for i in qs] response['data']['items'] = [{'name': i[name], 'items': i[items]} for i in qs]
else: else:
response['data']['items'] = qs.count() response['data']['items'] = qs.count()