Commit 6526ebc0 by Michael Frey

Revert "Check for top level image null"

This reverts commit 72386e07.
parent e2ed75c2
......@@ -191,7 +191,7 @@ class VoucherViewSet(NonDestroyableModelViewSet):
'contains_verified': is_verified,
'course_start_date': course_info['start'],
'id': course.id,
'image_url': course_info.get('image', '').get('src', ''),
'image_url': course_info['image'].get('src', ''),
'organization': CourseKey.from_string(course.id).org,
'seat_type': course.type,
'stockrecords': serializers.StockRecordSerializer(stock_record).data,
......
......@@ -108,7 +108,7 @@ class BasketSummaryView(BasketView):
try:
course = get_course_info_from_catalog(self.request.site, course_key)
description = course['short_description']
image_url = course.get('image', '').get('src', '')
image_url = course['image'].get('src', ''),
short_description = description if description else ''
course_name = course['title']
except (ConnectionError, SlumberBaseException, Timeout):
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment