Actions
Bug #16204
closedTypeAhead Prefetch Expects String Array Given
Start date:
12.05.2023
Due date:
% Done:
0%
Estimated time:
Discuss:
Prio Planung:
No
Description
maxLength is automatically set based on the column type maxlength of the database.
addding a check if a typeahead is set resolves this issue.
if ($this->maxLength > 0 && $this->value !== '') { // Check if there are \r\n > those should be counted as one char, not two. #13030 $crlf = substr_count($this->value, "\r\n"); $max = $this->maxLength + $crlf; // crop string only if it's not empty (substr returns false on empty strings) $this->value = mb_substr($this->value, 0, $max); }
Actions