about summary refs log tree commit diff
path: root/bh20simplewebuploader
diff options
context:
space:
mode:
Diffstat (limited to 'bh20simplewebuploader')
-rw-r--r--bh20simplewebuploader/main.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/bh20simplewebuploader/main.py b/bh20simplewebuploader/main.py
index b4e8681..bfc7762 100644
--- a/bh20simplewebuploader/main.py
+++ b/bh20simplewebuploader/main.py
@@ -88,7 +88,11 @@ def generate_form(schema):
             if not isinstance(field_type, str):
                 # If the type isn't a string
                 # See if it has a more info/what goes here URL
-                ref_url = field_type.get('jsonldPredicate', {}).get('_id', None)
+                predicate = field_type.get('jsonldPredicate', {})
+                if not isinstance(predicate, str):
+                    ref_url = predicate.get('_id', None)
+                else:
+                    ref_url = predicate # not sure this is correct
                 # Grab out its type field
                 field_type = field_type.get('type', '')