Question about Focus retry

If the focus fails to meet the max HFD number of retries specified. What focus position is used. I believe it uses the previous focuser position. Here is my question, does it use the previous focuser position for the filter being focused on, or does it use the last focuser position for the previous filter that met the HFD requirement? Example switching from Ha to OIII needs a refocus, if OIII retries fails does it use the previous OIII or Ha filter position that met the HFD requirement ?

Always the last focus position (equal to the position before start the focus).

All the best
LO