Ammal Farahat, who has signed up to be a driver for Careem, a regional ride-hailing service that is a competitor to Uber, drives her car in Riyadh, Saudi Arabia, on June 24. (Nariman El-Mofty/AP)

Sunday at midnight, the streets of Saudi Arabia were alive with the sounds of women revving car engines and driving. For the first time, they were allowed to operate motor vehicles without fear of arrest and detention. Under the driving ban, if a woman was arrested, she was held until a male guardian came and picked her up — but only after he signed a pledge that she would not drive again.

For decades, Saudi society was divided over the issue of women driving between the so-called liberals and the religious bloc. The latter presented the issue as a matter of “Halal and Haram” through the sharia (Islamic law), making it difficult to even debate — even though many other Muslim countries have allowed women to drive cars. Fatwas of prohibition were issued by senior official scholars in Saudi Arabia.

The media had its hands tied. The Saudi government was not keen to have a public debate about women driving. It guided the newspapers toward shutting down the conversation anytime it began to gain traction in society. It also played the neutrality card between liberals and the more religious Saudis. Moreover, some senior princes, like late Crown Prince Nayef, opposed letting women drive. He had been a powerful figure for decades and ran the Interior Ministry, holding sway over what happened in the kingdom.

His objection, like that of so many, wasn’t really on religious grounds as much as it was based on male chauvinism. Many Saudi clerics believe that letting women drive means they will be free to leave the house whenever they like — something that will have a liberalizing and therefore unwanted effect on society. Sheikh Saleh al-Fawzan, a member of the Council of Senior Scholars, said as much in a televised interview. He certainly won’t be saying that now, not after the government has gone ahead with lifting the ban.

Prince Sultan, a former crown prince and defense minister, was more diplomatic. He said it was not the government that had a problem with letting women drive, but rather, the people. Saudi officials found in his statements an opportunity to evade the question whenever the Western media raised the issue. The tenor of his opposition, though, actually encouraged the pro-driving movement now enjoying the taste of victory. The movement was led by an emerging generation of Saudi women such as Manal al-Sharif (now living in Australia) and Loujain al-Hathloul (recently detained by Saudi authorities) who got behind the wheel in Saudi Arabiavideotaped it and posted the footage to social media to emphasize the need for change.

The Saudi media had the responsibility to cover the debate, even though we knew the government did not want it publicized. Many officials wanted to solve this dilemma, due in part to economic pressures, as well as the increased numbers of women working thanks to the education they were getting for the first time. When females were finally allowed to enroll in Saudi universities, they eventually exceeded the number of males, yet this was not reflected in the labor market.

As editor of the newspaper Al-Watan in 2007, I bypassed the ban on public debate over the issue by publishing a series of clever articles by the brilliant writer Abdullah al-Fawzan. He imagined a girl riding a camel to her university and the ensuing predicament. The school doesn’t know where to park the camel. The policeman cannot figure out how to deal with the camel. The girl, meanwhile, rides to school on a road alongside car drivers who don’t know what to make of the camel because the law does not prohibit it. If she was driving a car, the policeman’s task was made easier; any official had instructions to take the girl to the police station and contact her legal guardian.

At the time it was published, it was a controversial article. We received letters in support of the piece, but those who opposed women driving were organized and more persistent. A week later, we ran the same article but now the girl was driving a bicycle. Then we ran another story in which she was riding a donkey. That way, we kept the issue alive while waiting for the government to make a change.

On television, three years ago, I debated a hard-line cleric who based his arguments against women driving on religion. He talked about the “freedom of women” and the destruction of society. Beyond banning women from driving, he offered other repressive ideas for suppressing women’s participation in society. We need to remember that women in Saudi Arabia did not get their right to education until the 1960s, and only after a similar fight.

Eventually, I had to give up my part in keeping the national conversation alive. My decision was brought to the attention of the most famous female TV personality in Saudi Arabia, Badriya Al Bishr (the Saudi Oprah Winfrey), who asked me on air why I took this stance.

“The different parties presented their argument more than once,” I told her, “and the government needs to step up and make the decision.” I said that the government should be courageous and bring an otherwise sterile debate to an end. I wasn’t optimistic that a quick decision was in the offing. I had become tired of going around in circles. The government always had multiple economic, social and political reasons to allow women to drive. It simply lacked the courage to move ahead.

Crown Prince Mohammed bin Salman deserves consider credit for bringing the matter to a close the right way. While previous leaders were reluctant to take up the issue, he faced it head-on and did the right thing for Saudi Arabia. At the same time, I hope he will not forget the brave actions of each and every Saudi who individually worked hard for freedom and modernization. He should order the release of Hathloul, Aziza al-Yousef, Eman al-Nafjan and the other brave women who campaigned for women’s right to drive. They should be allowed to finally witness the results of their tears and toil.