Where the former Labour-run Scottish Executive had failed on cutting NHS waiting times for treatment, the minority SNP Government elected in 2007 delivered.

Nicola Sturgeon, as health secretary, had attacked Labour while in opposition for using “hidden waiting lists” – lists of people not treated in line with targets but instead given codes keeping them out of official figures.

She abolished these and set up the new system, currently under tough scrutiny, in 2008.

Now in a different job focusing on the campaign for an independent Scotland, she still appears to be well respected within the health community.

However, the NHS Lothian scandal, which cast doubt on the veracity of waiting times performance figures nationwide, has cracked the solid foundation on which she stood.

At the very least there were oversights when Ms Sturgeon’s “new ways” system of looking after people on waiting lists was introduced.

Checks and balances which may have flagged-up potential misuse have been missing and the information technology used in some parts of Scotland has made it impossible to verify that patients have been dealt with honestly.

Furthermore, there were warnings that the system needed to be looked at more closely to stop a scandal, such as that at NHS Lothian, from happening.

In 2010, Audit Scotland published a report on waiting lists – well over a year before allegations of manipulation began emerging.

In it health boards were told to record more information to ensure that all patients were being managed in line with the guidance and the Scottish Government was advised more guidance was needed to make sure all patients are managed fairly across Scotland.

The increasing use of social unavailability codes was not flagged up specifically, but this data was held separately.

Audit Scotland said today if this had been scrutinised it could also have alerted officials to potential concerns.

This history must be embarrassing for Ms Sturgeon.

However minimal the level of manipulation, it tarnishes some of the waiting times success of the SNP Government.

It is hard to trust the very figures the Government came in determined to make more transparent.

Perhaps more seriously, though, the manipulation of waiting times results masks the real problem of lack of capacity in NHS Scotland to cope with demand.

There are others signs hospitals can’t cope with patient numbers too, including people waiting more than 12 hours in A&E departments over the recent festive season because of bed shortages.

While it is very difficult for patients to know how NHS administrators are protecting their place on an electronic queue, they know only too well when NHS staff on the frontline are struggling to cope.

More troubling reports from this side of the system would perhaps cast a darker shadow over the way Ms Sturgeon’s legacy on health care is viewed.