def createUserObject(master, author, src=None):
 if (not src):
  log.msg('No vcs information found, unable to create User Object')
  return defer.succeed(None)
 if (src in srcs):
  usdict = dict(identifier=author, attr_type=src, attr_data=author)
 else:
  log.msg(('Unrecognized source argument: %s' % src))
  return defer.succeed(None)
 return master.db.users.findUserByAttr(identifier=usdict['identifier'], attr_type=usdict['attr_type'], attr_data=usdict['attr_data'])

def createUserObject ( master , author , src = None ) : if ( not src ) : log . msg ( 'No vcs information found, unable to create User Object' ) return defer . succeed ( None ) if ( src in srcs ) : usdict = dict ( identifier = author , attr_type = src , attr_data = author ) else : log . msg ( ( 'Unrecognized source argument: %s' % src ) ) return defer . succeed ( None ) return master . db . users . findUserByAttr ( identifier = usdict [ 'identifier' ] , attr_type = usdict [ 'attr_type' ] , attr_data = usdict [ 'attr_data' ] )
take a change author and source and translate them into a user object .