The council was ordered to reconsider the 'unlawful' decision