aboutsummaryrefslogtreecommitdiffhomepage
path: root/crates/shirabe-external-packages/src/symfony/console/helper/helper.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/shirabe-external-packages/src/symfony/console/helper/helper.rs')
-rw-r--r--crates/shirabe-external-packages/src/symfony/console/helper/helper.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/crates/shirabe-external-packages/src/symfony/console/helper/helper.rs b/crates/shirabe-external-packages/src/symfony/console/helper/helper.rs
index 07b1f77..cc49f0a 100644
--- a/crates/shirabe-external-packages/src/symfony/console/helper/helper.rs
+++ b/crates/shirabe-external-packages/src/symfony/console/helper/helper.rs
@@ -38,7 +38,7 @@ impl Helper {
/// Returns the width of a string, using mb_strwidth if it is available.
/// The width is how many characters positions the string will use.
pub fn width(string: &str) -> i64 {
- if shirabe_php_shim::preg_match("//u", string, &mut Vec::new()) != 0 {
+ if shirabe_php_shim::preg_match("//u", string, &mut Vec::new()) {
return UnicodeString::new(string).width(false);
}
@@ -54,7 +54,7 @@ impl Helper {
/// Returns the length of a string, using mb_strlen if it is available.
/// The length is related to how many bytes the string will use.
pub fn length(string: &str) -> i64 {
- if shirabe_php_shim::preg_match("//u", string, &mut Vec::new()) != 0 {
+ if shirabe_php_shim::preg_match("//u", string, &mut Vec::new()) {
return UnicodeString::new(string).length();
}