I had a thought about this so I looked into the part numbers for that front brake line. They are different. I’m assuming it’s because the X has a lower clamp, therefore the hard straight part of the brake line may be a couple of inches longer. Looking at stock photos side by side this appears to be the case.
I still think it will not be an issue. Just make sure the clamp holds the line securely. If you’re really worried about it, it looks like you can pick up an X brake line for 40 some dollars from rocky mountain atv/mc.