Facebook is facing a major new privacy gaffe.

A bug was live from May 18 to May 27 where about 14 million Facebook users around the world had their default sharing setting for all new posts set to public, the company revealed. After Facebook employees discovered the bug, which occurred while the tech giant was testing a new feature, the company claimed workers went back and changed the privacy settings for all posts shared by those 14 million users during that time.

“We recently found a bug that automatically suggested posting publicly when some people were creating their Facebook posts. 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. To be clear, this bug did not impact anything people had posted before — and they could still choose their audience just as they always have. We’d like to apologize for this mistake,” Erin Egan, chief privacy officer of Facebook, told Fox News.

Affected Facebook users received a notification on the app or website starting Thursday. The message from Facebook urged users to “Please Review Your Posts,” and gave them a link to a list of what they shared on Facebook while the bug was active.

The news followed a recent furor over Facebook’s sharing of user data — oversharing, in the eyes of many critics.

Facebook also said Thursday it would end its data partnership with Huawei by the end of this week following a backlash over the Chinese phone maker’s access to Facebook user data.

Huawei claimed Wednesday it neither collected nor stored Facebook user data, after the social media giant acknowledged it shared such data with Huawei and other manufacturers.

Huawei, a company flagged by U.S. intelligence officials as a national security threat, was the latest device maker at the center of a fresh wave of allegations over Facebook’s handling of private data.

The development marked the latest major blunder for Facebook since allegations emerged in March that a Trump-affiliated political consultancy firm, Cambridge Analytica, had improperly harvested data from tens of millions of Facebook users to influence elections.

Fox News’ Shira Bush and The Associated Press contributed to this report.