Commit 0e5afb66 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

support the recent cloudooo that returns keywords as a list, not as a string.

parent 71bde9ab
...@@ -77,7 +77,11 @@ for k, v in information.items(): \n ...@@ -77,7 +77,11 @@ for k, v in information.items(): \n
if p is not None:\n if p is not None:\n
result[\'contributor\'] = p.getRelativeUrl()\n result[\'contributor\'] = p.getRelativeUrl()\n
elif key == \'keywords\':\n elif key == \'keywords\':\n
result[\'subject_list\'] = v.split()\n if isinstance(v, (list, tuple)):\n
v = [isinstance(x, unicode) and x.encode(\'utf-8\') or x for x in v]\n
else:\n
v = v.split()\n
result[\'subject_list\'] = v\n
\n \n
# Erase titles which are meaningless\n # Erase titles which are meaningless\n
title = result.get(\'title\', None)\n title = result.get(\'title\', None)\n
......
152 153
\ No newline at end of file \ No newline at end of file
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