Catalysis of the reaction: 5-dehydroepisterol + H+ + NADPH + O2 = ergosta-5,7,22,24(28)-tetraen-3beta-ol + 2 H2O + NADP+. This reaction is the introduction of a double bond between the C-22 and C-23 carbons of certain sterols. Also converts sitosterol and 24-epi-campesterol to stigmasterol and brassicasterol, respectively.
C-22 sterol desaturase (NADPH) activity