I look at it the same way as the
Coruscant Industrial Zone. Even when CIZ itself is being replaced by another face-up card, thereby removing CIZ from play, it still grants a unit from reserves because the ability was active during the objective swap part of the turn.
If Aayla Secura follows the same pattern, then its ability is active during the combat action taking place and can indeed perhaps count the Jedi bonus. One thing to keep in mind is that there are no "phases" of battle as other TCGs utilize, and the ability does not specify
when during the battle it needs to be discarded.
Another thing to consider is that the discard ability remains active
after the objective is replaced. Therefore, the counting of a bonus added to a unit base stat is possible even after an objective is removed, and counting the Jedi bonus could be considered as valid as the discard ability.