The Flintstones - Season 1 Episode 21 Love Letters on the Rocks Yabba Dabba Doo!
Overview: Jealous Fred's discovery of a love poem that was sent to Wilma prompts him to hire Bedrock's top detective Perry Gunite, to find out who the home-wrecking poet is. Gunite's investigation mistakenly points to Barney. Fred plans revenge against his friend until Wilma reminds her husband that he had written the poem himself years earlier during their courtship.