def db_init(): """ Function to initialize DB, create and add tables """ DB.init('customer.db') DB.create_tables([Customer]) add_customer(CUSTOMER_LIST)
def db_init(): """ Function to initialize DB, create/add tables and add customer data to the DB """ DB.init('customer.db') DB.create_tables([Customer]) [ add_customer(customer) for customer in CUSTOMER_LIST if customer is not None ]