People walk under elelction posters for Turkey's President Tayyip Erdogan and Muharrem Ince, Presidential candidate of Turkey's main opposition Republican People's Party (CHP) in Istanbul, Turkey June 13, 2018. REUTERS/Osman Orsal

ISTANBUL (Reuters) - Turkish President Tayyip Erdogan has said the state of emergency that has been in place since July 2016 will be lifted if he is elected in June 24 elections, but suggested it would be reinstated if the country faces further threats.

“Should I continue this task after June 24, the first thing we’ll do is, God willing, lift the state of emergency,” Erdogan said in an interview with 24 TV on Wednesday night.

“Lifting the state of emergency does not mean abolishing it completely not to come back. We’ll take whatever the toughest precaution is again when we see terror.”

The state of emergency lets Erdogan and the government bypass parliament in passing new laws and allows them to suspend rights and freedoms. It was declared shortly after a failed coup attempt in July 2016 and has been extended every three months since then.

More than 160,000 people have been detained under the emergency rule and a similar number of civil servants have been sacked from their jobs, the United Nations has said. Scores of media outlets have been shut and journalists and activists have been detained.

Critics say Erdogan is using the state of emergency as a pretext to quash dissent. Turkey has said the measures are necessary to fend off the security threats it faces and that the state of emergency does not interfere with the campaign.

Erdogan said in April that businesses should welcome the state of emergency because it guards against terrorism and prevents workers from going on strike.