It was illegal then and it's illegal now. The circuit court didn't say "as of May 7th, 2015 this is illegal"; they said that the NSA exceeded the scope of surveillance authorized by Congress in October of 2001.
You claimed the metadata collection program was "written about at length" and viewed as "OK". This is evidence from the judicial branch of the US government it is not, in fact, viewed as okay.