[PLAT-5125] Added support for compounding legs on new swap security