Apple on Wednesday removed an app that protesters in Hong Kong used to track police movements from its app store.

Apple said the use of the app violated its rules because, it was used to ambush the police as well as used by criminals to victimize residents in areas with no law enforcements.

The tech giant had come under fire from China over the app, with the Chinese Communist Party’s official newspaper calling the app “poisonous” and decrying what it said was Apple’s complicity in helping the Hong Kong protesters.

Apple said in a statement that it had began an immediate investigation after “many concerned customers in Hong Kong” contacted the company about the app and Apple found out it had endangered law enforcement and residents.

“The app displays police locations and we have verified with the Hong Kong Cybersecurity and Technology Crime Bureau that the app has been used to target and ambush police, threaten public safety, and criminals have used it to victimize residents in areas where they know there is no law enforcement,” the statement said.

Under Apple’s rules and policies, apps that meet its standards to appear in the App Store have sometimes been removed after their release, if they were found to facilitate illegal activity or threaten public safety.

Source: Reuters