Facebook said Thursday that it would notify 14 million users that posts they intended to share privately may have been published publicly, the company’s latest setback as it tries to rebuild user trust after the Cambridge Analytica scandal.

The issue arose from a bug affecting Facebook’s “audience selector” tool, which allows users to decide whether to publish a post only to their friends or to a broader audience. The tool usually remains on the setting that was used most recently so that a user who only wants to share posts with friends does not have to keep selecting that option. But while the bug was active, from 18 May to 27 May, the setting was automatically changed to public.

“We have fixed this issue and starting today we are letting everyone affected know and asking them to review any posts they made during that time,” Erin Egan, Facebook’s chief privacy officer, said in a statement. “We’d like to apologize for this mistake.”

Facebook said it had reverted the audience settings to users’ prior preference. It will also show affected users a notification with an explanation and apology, and urge them to review any posts they made during the time period when the bug was active.

The company’s quick admission of the error appears to be part of its efforts to increase transparency and regain trust following the Cambridge Analytica revelations. This spring, Facebook was harshly criticized for failing to inform users whose data had been improperly shared with the political consultancy until more than two years after the Guardian had first reported on the issue.

The two privacy lapses involve very different types of data, however. Jonathan Albright, the research director at the Tow Center for Digital Journalism at Columbia University, has argued that Facebook’s audience tools, which it often touts as giving user’s control over their privacy, should instead be deemed “publicity settings”, because they only affect the audience of information that a user chooses to publish.

The data involved in the Cambridge Analytica scandal was the massive amounts of information that Facebook gathers from users’ online behavior – such as liking posts or browsing the web – in order to target them with advertising.