Add twitter to json

This commit is contained in:
Scott Bragg 2017-01-15 09:55:53 +11:00
parent 4e22717639
commit 8cf4bf3490

View file

@ -251,6 +251,8 @@ def schedule_json(request):
), ),
"cancelled": slot.content.cancelled, "cancelled": slot.content.cancelled,
}) })
if not slot.content.speaker.twitter_username == '':
slot_data["twitter_id"] = slot.content.speaker.twitter_username
else: else:
slot_data.update({ slot_data.update({
"name": slot.content_override if slot.content_override else "Slot", "name": slot.content_override if slot.content_override else "Slot",