incubator-allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tvansteenbu...@apache.org
Subject git commit: [#6612] Handle missing fields in imported json
Date Fri, 27 Sep 2013 16:10:17 GMT
Updated Branches:
  refs/heads/master a580f3ecb -> acfb7b50a


[#6612] Handle missing fields in imported json

Signed-off-by: Tim Van Steenburgh <tvansteenburgh@gmail.com>


Project: http://git-wip-us.apache.org/repos/asf/incubator-allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-allura/commit/acfb7b50
Tree: http://git-wip-us.apache.org/repos/asf/incubator-allura/tree/acfb7b50
Diff: http://git-wip-us.apache.org/repos/asf/incubator-allura/diff/acfb7b50

Branch: refs/heads/master
Commit: acfb7b50a11cdd6fb35604f1c899e75e669dd24b
Parents: a580f3e
Author: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Authored: Fri Sep 27 16:09:01 2013 +0000
Committer: Tim Van Steenburgh <tvansteenburgh@gmail.com>
Committed: Fri Sep 27 16:09:54 2013 +0000

----------------------------------------------------------------------
 ForgeTracker/forgetracker/import_support.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-allura/blob/acfb7b50/ForgeTracker/forgetracker/import_support.py
----------------------------------------------------------------------
diff --git a/ForgeTracker/forgetracker/import_support.py b/ForgeTracker/forgetracker/import_support.py
index ef649dc..381e711 100644
--- a/ForgeTracker/forgetracker/import_support.py
+++ b/ForgeTracker/forgetracker/import_support.py
@@ -206,10 +206,10 @@ class ImportSupport(object):
 
         description = h.really_unicode(self.link_processing(remapped['description']))
         creator = owner = ''
-        if ticket_dict['submitter'] and not remapped['reported_by_id']:
+        if ticket_dict.get('submitter') and not remapped.get('reported_by_id'):
             creator = u'*Originally created by:* {0}\n'.format(
                     h.really_unicode(ticket_dict['submitter']))
-        if ticket_dict['assigned_to'] and not remapped['assigned_to_id']:
+        if ticket_dict.get('assigned_to') and not remapped.get('assigned_to_id'):
             owner = u'*Originally owned by:* {0}\n'.format(
                     h.really_unicode(ticket_dict['assigned_to']))
         remapped['description'] = u'{0}{1}{2}{3}'.format(creator, owner,


Mime
View raw message