@click.command(u'clear-limits')
@click.option(u'--site', help=u'site name')
@click.argument(u'limits', nargs=(-1), type=click.Choice([u'emails', u'space', u'users', u'email_group', u'expiry', u'support_email', u'support_chat', u'upgrade_url']))
@pass_context
def clear_limits(context, site, limits):
 from frappe.limits import clear_limit as _clear_limit
 if (not limits):
  return
 if (not site):
  site = get_site(context)
 with frappe.init_site(site):
  _clear_limit(limits)
  limits = get_limits()
  if (not limits):
   update_site_config(u'limits', u'None', validate=False)

@ click . command ( u'clear-limits' ) @ click . option ( u'--site' , help = u'site name' ) @ click . argument ( u'limits' , nargs = ( - 1 ) , type = click . Choice ( [ u'emails' , u'space' , u'users' , u'email_group' , u'expiry' , u'support_email' , u'support_chat' , u'upgrade_url' ] ) ) @ pass_context def clear_limits ( context , site , limits ) : from frappe . limits import clear_limit as _clear_limit if ( not limits ) : return if ( not site ) : site = get_site ( context ) with frappe . init_site ( site ) : _clear_limit ( limits ) limits = get_limits ( ) if ( not limits ) : update_site_config ( u'limits' , u'None' , validate = False )
clears given limit from the site config .