Legalisation logic fix

Pivotal: https://www.pivotaltracker.com/story/show/47288605