| 33 | | entry['content'] = entry['summary'] |
| | 33 | if 'summary' in entry: |
| | 34 | entry['content'] = entry['summary'] |
| | 35 | elif 'title_detail' in entry: |
| | 36 | entry['content'] = entry['title_detail']['value'] |
| | 37 | else: |
| | 38 | entry['content'] = u'' |
| | 39 | |
| | 40 | content = entry['content'] |
| | 41 | |
| | 42 | # better parsiong to be done here |
| | 43 | if isinstance(content, list): |
| | 44 | content = content[0] |
| | 45 | |
| | 46 | if not isinstance(content, basestring): |
| | 47 | if isinstance(content, dict) and 'value' in content: |
| | 48 | entry['content'] = content['value'] |
| | 49 | else: |
| | 50 | entry['content'] = u'' |
| | 51 | |