The knife has not been used for meat for a very long time, it was only used for onions or vegetables. I used it by mistake for frying onions on a milichig pot should I throw away the pot? should I have thrown away the food?
Although the knife was not used for a long time, since it was once meaty and onion is sharp the meaty element absorbed in the knife is considered "revived" and therefore the onion is considered meaty. If the onions fried were the majority of the food being fried you may not eat the onions and the pot must be kashered it does not have to be thrown away unless it can't be made kosher. (Shuchan Aruch Yoreh Deah 95 and 96 and Shach 6)