I had to build a small screen porch just outside my door so that it would act as a catlock (airlock).
Both doors are never open at the same time.
After a few attempts were foiled, Sweetpea, hardly ever trys anymore.
That, & I built a 20'x40' catio w/ enclosed walkway so my 3 cats can go outdoors.