fix bug causing restrictions to be ignored

illegalPairs was renamed to restrictions, but not everywhere.
This has to be fixed, this is a temporary patch.