Fixed insert. It now inserts the foi_array and not an empty row.