Ugh, that's the worst kind of noise. It's such a relief when the fix turns out to be something cheap and simple like that, instead of a whole new set of parts. Glad you got it sorted.
Actually, cleaning them can help a ton, but sometimes the squeal really is from the pads or rotors just being worn out. That stuff gets thin and starts making noise.
Right, but the squeal from worn parts is usually a different pitch. Thin pads grinding on a rotor sound more like a constant metal-on-metal groan. The high-pitched squeak you get when you first tap the brakes is almost always from vibration, and cleaning or a bit of grease on the pad backing plate stops it cold.