<?php


if (!defined('_PS_VERSION_')) {
    exit;
}

function upgrade_module_1_0_2($module)
{
    # This update was forgotten in the SQL fresh install script on 1.0.1 for Prestashop 1.6...
    Db::getInstance()->execute(
        'CREATE TABLE IF NOT EXISTS `'._DB_PREFIX_.'lce_cart_selected_relay` (
        `id_cart` int(10) NOT null,
        `relay_code` varchar(10) NOT null,
        PRIMARY KEY (`id_cart`)
        ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8;'
    );

    # Added a new option. Set to true by default.
    Configuration::updateValue('MOD_LCE_UPDATE_ORDER_STATUS', '1');

    return true;
}
