Hi,
You could try setting up an alternate appearance on FaceID and seeing if that works.
You could also make sure you have the latest iOS installed.
But here’s the thing, if you change your earpiece flex you lose FaceID straightaway, unless you transfer the chips from the old flex to the new one.
So if you have FaceID working, (you or someone else) must have transferred the chips, so the issue could be that one of the chips wasn’t cleaned and reflowed properly and has poor contact on the solder joint/s and may need redoing.
Hope this helps