def purge_options(app, env, docname):
 if (not hasattr(env, 'optionlist_all_options')):
  return
 env.optionlist_all_options = [option for option in env.optionlist_all_options if (option['docname'] != docname)]
 env.optionlist_indexed_options = dict([(option['options']['config'], option) for option in env.optionlist_all_options])

def purge_options ( app , env , docname ) : if ( not hasattr ( env , 'optionlist_all_options' ) ) : return env . optionlist_all_options = [ option for option in env . optionlist_all_options if ( option [ 'docname' ] != docname ) ] env . optionlist_indexed_options = dict ( [ ( option [ 'options' ] [ 'config' ] , option ) for option in env . optionlist_all_options ] )
clear our data from the environment when necessary .