Skip to content

Commit ff48890

Browse files
committed
field mask may not contain '_'
1 parent 65008b4 commit ff48890

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

php/ext/google/protobuf/php-upb.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1875,8 +1875,8 @@ static upb_StringView jsondec_mask(jsondec* d, const char* buf,
18751875
if (ch >= 'A' && ch <= 'Z') {
18761876
*out++ = '_';
18771877
*out++ = ch + 32;
1878-
} else if (ch == '_') {
1879-
jsondec_err(d, "field mask may not contain '_'");
1878+
// } else if (ch == '_') {
1879+
// jsondec_err(d, "field mask may not contain '_'");
18801880
} else {
18811881
*out++ = ch;
18821882
}

php/tests/field_mask_test.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
$m1 = new FieldMask();
99
$m2 = new FieldMask();
1010

11-
$m1->setPaths(['phoneNumber', 'emailAddress']);
11+
$m1->setPaths(['phoneNumber', 'email_address']);
1212

1313
$m2->mergeFromJsonString($m1->serializeToJsonString());
1414

0 commit comments

Comments
 (0)