Просто замените его, введя данные в массив, как показано ниже.
function get_products() {
try {
vtexjs.checkout.getOrderForm().done(function(a) {
console.log("Push order", a);
arr_products_cart = [];
$(a.items).each(function(a, b) {
arr_products_cart.push({
name: b.name,
id: b.id,
price: if ("0,01" === b.listPrice || "0.01" === b.listPrice)
"0.00"
else
b.listPrice
brand: brand,
category: b.productCategories[Object.keys(b.productCategories)[1]],
variant: b.skuName
});
arr_products_cart_category.push({
id: b.id,
category: b.productCategories[Object.keys(b.productCategories)[1]],
variant: b.skuName
});
});
set_products_cart();
cart_qty_register_category();
});
} catch (a) {
console.warn("get_products error", a);
}
}