The daughter of a family friend died of a peanut allergy. She was at a wedding reception, on the dance floor, and one of the horsdouvers other guests were eating was cooked in peanut oil. Her epipen was in her purse at her table, and she couldn't make it back to the table in time.
So I think it is very reasonable for an airline to prevent nuts on a flight.
HOWEVER, the person with the allergy must claim the allergy when buying their ticket. We have to give the airline emergency contact information when we buy our tickets. Why can't they warn us in advance that it's going to be a nut-free flight? Then we can pack accordingly. And everyone is happy.