Controversial anti-corruption guidance for police officers that equated journalists with criminals has been changed.