Q: If somebody feeds you something haraam and you find out later that it was haraam will you get the punishment of your prayers not being accepted for 40 days?
A: It was done unintentionally. Istighfaar (asking repentance) should still be done and it will not affect the prayers.
Moulana Yusuf Laher