British government plans to cut subsidies for solar panels on homes were ruled legally flawed by the High Court on Wednesday.