Cook onions until soft and with sweet flavor, being careful not to burn them. If too moist, drain in a colander or air dry on a plate. Mix the onions into the dough until well combined, being gentle to avoid mashing them.