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,10 +212,7 @@ Positions
elif 'range' in data:
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:
response['data']['items'] = qs.count()
elif 'ids' in query: