AIUI modern FBW jets will not permit the stall to be entered, instead holding the AOA just below the stall. If the aircraft was at or near AOAmax when the flaps retracted, I would expect the FCS to command a pitch down to reduce the AOA, which could actually worsen the glidepath.
Pitch down or up?
My guess would be pitch up as retracting the flaps when maintaining pitch would reduce aoa.
Either way I don't think it would be a good idea to move em.