If your bird was going to try onion and garlic.. at least they were cooked in an acid (tomato). This would have changed a lot about the chemical state and amino acid chains. The salt would be the biggest concern. Clearly this is not an endorsement to feed onion, garlic or any of the non-safe bird foods to birds.. if Lucy was going to go ahead and try.. whew... much better than eating fresh onion or the like.
Onion and garlic are scary things, humans are one of the only organisms that can really eat them. I am personally onion intolerant, not anaphylaxis like other allergies, but I do have many complications from onions..not limited to becoming immune compromised whilst my body fights it... So then I can easily pick up other illnesses. Interestingly enough when onion is cooked in a tomato sauce or salsa and canned.. the acid and heat change the amino acid so I am no longer reactive to it. This also happens a lot for people with shellfish allergies. Typically a 100% cooked prawn will not create a reaction...however if even 1 amino acid chain hasn't been broken down they can get anaphylaxis. I personally can't eat fresh salsa or tomato sauces, because it is never cooked as thoroughly as canned.
I will point out that onions have been poorly researched in birds. --there have been cases of geese and ducks perishing from onion..
How Toxic Are Onions To Parrots?
Top Ten Bird Killers "Onions can cause a fatal hemolytic anemia in dogs and cats, but since birds' red blood cells have a nucleus, this may protect the cells from the severe injury that occurs in other species. However, until this topic is studied, it is best to not feed onions to birds."