The problem is that too many commas impede the flow of words and ideas, so that the extra comma is often omitted in short combinations. It is a style decision rather than a matter of 'correctness'. I suggest: John had been told that pigs could fly, but in his opinion, this was incorrect.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.