I replaced passenger headlight when it went out. Replaced drivers headlight a couple months ago but both have went out at the same time since they have both been replaced. Jiggling wiring, they come back on but have still been going out some.
Fix the wiring. You damaged it when you replaced the bulbs.
The connectors are probably melted . . . very common on GM products
Yep, I’ve done both sides on my wife’s 2012 Malibu. Replacement plugs are likely under $5 each.