A brake snake can help here, I have them on the gear lever as well to stop trees getting wedged in-between & levering the lever out or the ground grabbing it when you fall off. Sadly there’s not much forward high enough to tie to on the KDX.
You can buy brake snakes from shops or just use an old throttle cable inner & some crimps from a fishing shop.