The past perfect would be fine in both of your sentences. The simple answer to your question is that native speakers are frequently less convrened about backshifting from past to past perfect than some student grammars suggest they should be. " in the second sentence.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.