diff --git a/phpgwapi/inc/common_functions.inc.php b/phpgwapi/inc/common_functions.inc.php index 73fd1f5f15..4e49a3ffd7 100755 --- a/phpgwapi/inc/common_functions.inc.php +++ b/phpgwapi/inc/common_functions.inc.php @@ -67,7 +67,7 @@ function cut_bytes(&$data,$offset,$len=null) { return $func_overload & 2 ? mb_substr($data,$offset,bytes($data),'ascii') : substr($data,$offset); } - return $func_overload ? mb_substr($data,$offset,$len,'ascii') : substr($data,$offset,$len); + return $func_overload & 2 ? mb_substr($data,$offset,$len,'ascii') : substr($data,$offset,$len); } if (!function_exists('mb_strlen'))