I'm starting here from the conservative position both the UK food standards agency and the NHS take regarding reheating food. Both bodies state that food should only be reheated once.
So the filling is cooked and left to cool. The cold filling is then added to the pastry shell which is then partially or fully baked. The consumer then reheats this filling a third time when eating it after purchase.
Assuming everything is brought up to a sufficiently high temperature and refrigerated quickly, I cannot see any problem with this process other than the potential deterioration of the quality of the filling. The pies should still be safe to eat, however.
Are there any other techniques used commercially in the preparation of pies? If not, am I correct in assuming these food safety standards are over zealous in this instance?