Skip to content

Commit 727c068

Browse files
committed
ext/standard/string.c: use standard wording for ValueError in str_pad()
1 parent 74caba9 commit 727c068

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ext/standard/string.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5802,7 +5802,7 @@ PHP_FUNCTION(str_pad)
58025802
}
58035803

58045804
if (pad_str_len == 0) {
5805-
zend_argument_value_error(3, "must be a non-empty string");
5805+
zend_argument_cannot_be_empty_error(3);
58065806
RETURN_THROWS();
58075807
}
58085808

ext/standard/tests/strings/str_pad.phpt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,5 +302,5 @@ string(16) "\t\variation\t\t"
302302
#### error conditions ####
303303

304304
--- empty padding string ---
305-
str_pad(): Argument #3 ($pad_string) must be a non-empty string
305+
str_pad(): Argument #3 ($pad_string) cannot be empty
306306
str_pad(): Argument #4 ($pad_type) must be STR_PAD_LEFT, STR_PAD_RIGHT, or STR_PAD_BOTH

0 commit comments

Comments
 (0)