The judgement came after a case brought by environmental campaigners at the Court of Session in Edinburgh.