Wife was having trouble with a financials spreadsheet from work, and asked me to help out. I took a look, and although I didn't know the actual content, it was clear to me what the kind of error must be, and how to correctly design a spreadsheet so that such errors are easily identifiable.
She said she didn't know that the incoming data might be problematic; I replied that one must always treat all inputs as untrusted. She said that XYZ gave it to her; I said be defensive against bad data even if I give it to you.
Anyway... the whole thing turned into a conflict, when I could have just said "I'm glad I could help you this time".
Well, they could if she thought of it like that.
Well, that's the theory anyway.
My wife now frequently turns to me when she hears "facts", I've become a sort of a content filter for facts and trivia; not to mention an encyclopaedia too. I've still got to teach her a true understanding of the universe and our solar system, but I learnt all that by being a sci-fi nerd from when my dad showed me Star Wars at like 3. I've literally got almost two decades on her on that front.
What it has lead to is that I will often cede the point for the time being, I will then look up the relevant literature and either bring it up the next time I'm with the person or send them the link. I try to do this even if I'm wrong.
I'm sure it doesn't help me come off as sociable, but I like to contribute to the spread of fact-based discussion which we have so little of these days.
But really, it's way more important to get along and be happy than to prove I'm right about something that doesn't matter. (I still say it, but refrain from proving it.)