Page MenuHomePhabricator

D21758.diff
No OneTemporary

D21758.diff

diff --git a/src/utils/utf8.php b/src/utils/utf8.php
--- a/src/utils/utf8.php
+++ b/src/utils/utf8.php
@@ -314,6 +314,8 @@
* @return int The console display length of the string.
*/
function phutil_utf8_console_strlen($string) {
+ $string = phutil_string_cast($string);
+
// Formatting and colors don't contribute any width in the console.
$string = preg_replace("/\x1B\[\d*m/", '', $string);

File Metadata

Mime Type
text/plain
Expires
Thu, May 30, 9:15 AM (3 w, 6 d ago)
Storage Engine
blob
Storage Format
Encrypted (AES-256-CBC)
Storage Handle
6287251
Default Alt Text
D21758.diff (413 B)

Event Timeline