The Scottish National Party's (SNP) treasurer Colin Beattie has resigned after his arrest as part of an ongoing police investigation into the party's finances.
He was arrested on Tuesday and later released without charge.
He said he would also be stepping back from his role on the public audit committee, which works to make sure public money is spent appropriately and effectively, until the police investigation had concluded.
The treasurer's resignation shortly after the SNP's new leader Humza Yousaf made his first big speech on Tuesday, laying out his "new vision" for the party.
"This decision has not been easy, but it is the right decision to avoid further distraction to the important work being led by Humza Yousaf to improve the SNP's governance and transparency," Mr Beattie said in a statement.
"I will continue to cooperate fully with Police Scotland's enquiries and it would be inappropriate for me to comment any further on a live case."
SNP leader Mr Yousaf said the resignation was "the right thing to do" and that a new treasurer would be appointed as soon as possible.
The police is currently investigating how the SNP has handled its finances - its money - with some senior members of the party recently being arrested and released as part of this investigation.
What did Humza say in his first speech as leader?
On Tuesday, the Scottish first minister, who was elected party leader in March, outlined three main priorities for the SNP to focus on over the next three years: Tackling poverty, building a "fair, green and growing" economy, and improving public services.
He also outlined changes to policies that were announced before he became the party's leader.
His main focuses are poverty, the economy and public services - which means things like buses and hospitals.
He also used the speech to change or delay some plans that had been made by the previous SNP leader, Nicola Sturgeon.
One of these was the deposit return scheme that was supposed to begin in August.
The plan was to bring in a system where used bottles could be returned in exchange for 20p.
However Humza Yousaf announced that because of some criticisms of the system, it will be delayed until at least March 2024.
What challenges do the Scottish National Party face?
The first minister's speech came at a time of real difficulty for the SNP, as Police Scotland are currently investigating how the party have handled their finances.
The investigation, called Operation Branchform, has been going on since 2021.
It's happening because of complaints about how the party spent more than £600,000 of donations that it received from activists to fund a future independence referendum campaign.
Police are also looking into a loan of more than £100,000 that was not fully repaid.
And in recent weeks, senior members of the SNP have been arrested in relation to the party's money.
What's happened in the investigation so far?
In February 2023, key people within the party were interviewed by police about the missing £600,000.
In early April Peter Murrell, the husband of Nicola Sturgeon, (who resigned as SNP leader at the end of March) was arrested.
Murrell had previously served as the party's chief executive, but left in March after being accused of lying about how many members the party had.
His and Nicola Sturgeon's home in Glasgow was searched for two days by police, as were the SNP's headquarters.
The SNP treasurer (the person in charge of the party's money) Colin Beattie was arrested by police on Tuesday in relation to the investigation.
Both men were released without charge, which means they can leave the police station freely.
However they, and the party, are still being investigated.
On Wednesday afternoon Colin Beattie resigned from his role as party treasurer with immediate effect.
What are other parties in Scotland saying?
The Scottish Conservatives have said that Humza Yousaf should ban Nicola Sturgeon, her husband Peter Murrell, and Colin Beattie from the SNP.
Humza has so far said that he doesn't want to do this, and instead wants to wait until the police investigation has finished.
The leader of the Scottish Labour Party, Anas Sarwar, said in a speech that the SNP are not only covering things up but that they are also not doing their jobs properly, and that they are currently "a distracted and divided government that is disastrous for Scotland".
What is the first minister of Scotland saying?
Humza Yousaf has described the recent arrests as "a very serious matter indeed".
Regarding those from his party who have been arrested, he said that they are all "innocent until proven guilty", adding he wants to wait for the results of the investigation before imposing any suspensions.
He admitted there is "change that is needed with how the party is operated", and that he's committed to implementing that change.