In loomex you cannot just use 1 conductor as the bonding conductor has to be connected too. I am guessing you ran a 3 way switch and just used 2 X 2 wire loomex to accomplish this? I shows a lack of planning but I cannot see it as a violation. The unused conductor will have a voltage on it but I cannot see it will carry current or present a hazard as long as the unused ends are capped off.