File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -2872,20 +2872,20 @@ void TextFormat::Printer::PrintUnknownFields(
28722872 }
28732873}
28742874
2875- namespace {
2875+ namespace internal {
28762876
28772877// Check if the field is sensitive and should be redacted.
28782878bool ShouldRedactField (const FieldDescriptor* field) {
28792879 if (field->options ().debug_redact ()) return true ;
28802880 return false ;
28812881}
28822882
2883- } // namespace
2883+ } // namespace internal
28842884
28852885bool TextFormat::Printer::TryRedactFieldValue (
28862886 const Message& message, const FieldDescriptor* field,
28872887 BaseTextGenerator* generator, bool insert_value_separator) const {
2888- if (ShouldRedactField (field)) {
2888+ if (internal:: ShouldRedactField (field)) {
28892889 if (redact_debug_string_) {
28902890 IncrementRedactedFieldCounter ();
28912891 if (insert_value_separator) {
Original file line number Diff line number Diff line change @@ -71,6 +71,7 @@ PROTOBUF_EXPORT extern std::atomic<bool> enable_debug_text_format_marker;
7171PROTOBUF_EXPORT extern std::atomic<bool > enable_debug_text_detection;
7272PROTOBUF_EXPORT extern std::atomic<bool > enable_debug_text_redaction;
7373PROTOBUF_EXPORT int64_t GetRedactedFieldCount ();
74+ PROTOBUF_EXPORT bool ShouldRedactField (const FieldDescriptor* field);
7475
7576// This enum contains all the APIs that convert protos to human-readable
7677// formats. A higher-level API must correspond to a greater number than any
You can’t perform that action at this time.
0 commit comments