In The Hobbit, Thorin and company are imprisoned in the Elven king's dungeons. After a time, Bilbo helps Thorin and the Dwarves escape, and the Elven king seems to intend all along to take some of Smaug's treasure, either as it comes back through the forest or via siege before the gates of the Lonely Mountain.
In Fellowship of the Ring, Book 2 Chapter 2, The Council of Elrond, Gloin complains that Thranduil's (the Elven king's) people showed him and Thorin's folk less kindness than they showed Gollum. Gandalf stops him, saying the Dwarves' imprisonment was "a regrettable misunderstanding long set right."
How does Gandalf think this was set right? By the Elves helping during the Battle of Five Armies? And Bilbo paid Thranduil back generously anyway. One can't help but feel Gloin has a point...