Fixed management of formulas to use new cobra features