def boot_session(bootinfo):
 import frappe
 bootinfo.custom_css = (frappe.db.get_value(u'Style Settings', None, u'custom_css') or u'')
 bootinfo.website_settings = frappe.get_doc(u'Website Settings')
 if (frappe.session[u'user'] != u'Guest'):
  update_page_info(bootinfo)
  load_country_and_currency(bootinfo)
  bootinfo.notification_settings = frappe.get_doc(u'Notification Control', u'Notification Control')
  bootinfo.customer_count = frappe.db.sql(u'select count(*) from tabCustomer')[0][0]
  if (not bootinfo.customer_count):
   bootinfo.setup_complete = ((frappe.db.sql(u'select name from\n DCTB  DCTB  DCTB  DCTB tabCompany limit 1') and u'Yes') or u'No')
  bootinfo.docs += frappe.db.sql(u'select name, default_currency, cost_center,\n DCTB  DCTB  DCTB default_terms, default_letter_head, default_bank_account from `tabCompany`', as_dict=1, update={u'doctype': u':Company'})

def boot_session ( bootinfo ) : import frappe bootinfo . custom_css = ( frappe . db . get_value ( u'Style Settings' , None , u'custom_css' ) or u'' ) bootinfo . website_settings = frappe . get_doc ( u'Website Settings' ) if ( frappe . session [ u'user' ] != u'Guest' ) : update_page_info ( bootinfo ) load_country_and_currency ( bootinfo ) bootinfo . notification_settings = frappe . get_doc ( u'Notification Control' , u'Notification Control' ) bootinfo . customer_count = frappe . db . sql ( u'select count(*) from tabCustomer' ) [ 0 ] [ 0 ] if ( not bootinfo . customer_count ) : bootinfo . setup_complete = ( ( frappe . db . sql ( u'select name from\n DCTB  DCTB  DCTB  DCTB tabCompany limit 1' ) and u'Yes' ) or u'No' ) bootinfo . docs += frappe . db . sql ( u'select name, default_currency, cost_center,\n DCTB  DCTB  DCTB default_terms, default_letter_head, default_bank_account from `tabCompany`' , as_dict = 1 , update = { u'doctype' : u':Company' } )
boot session - send website info if guest .