def _oembed_for(thing, **embed_options):
 if isinstance(thing, Comment):
  return _oembed_comment(thing, **embed_options)
 elif isinstance(thing, Link):
  return _oembed_post(thing, **embed_options)
 raise NotImplementedError("Unable to render oembed for thing '%r'", thing)

def _oembed_for ( thing , ** embed_options ) : if isinstance ( thing , Comment ) : return _oembed_comment ( thing , ** embed_options ) elif isinstance ( thing , Link ) : return _oembed_post ( thing , ** embed_options ) raise NotImplementedError ( "Unable to render oembed for thing '%r'" , thing )
given a thing .