Who says that it is illegal. If no penalty was called, no foul occurred.
As you can see, W was not actually ON the rugby "pitch" but was only NEAR it, so the rules do not apply.