def register_trophy(trophy):
 warnings.warn(u'register_trophy() is deprecated. Please use reviewboard.accounts.trophies:trophies_registry.register() instead.', DeprecationWarning)
 if (not issubclass(trophy, TrophyType)):
  raise TypeError(u'Only TrophyType subclasses can be registered')
 try:
  trophies_registry.register(trophy)
 except AlreadyRegisteredError as e:
  raise KeyError(six.text_type(e))

def register_trophy ( trophy ) : warnings . warn ( u'register_trophy() is deprecated. Please use reviewboard.accounts.trophies:trophies_registry.register() instead.' , DeprecationWarning ) if ( not issubclass ( trophy , TrophyType ) ) : raise TypeError ( u'Only TrophyType subclasses can be registered' ) try : trophies_registry . register ( trophy ) except AlreadyRegisteredError as e : raise KeyError ( six . text_type ( e ) )
register a trophytype subclass .