Replace the substr function with mb_substr

Created on 13 March 2023, over 1 year ago
Updated 12 April 2023, over 1 year ago

Problem/Motivation

When a "text" or "string" field translation is bigger than 255bytes the module uses the php function substr to trim it. With special characters this can cause an error when saving the term.

Proposed resolution

Replace the substr function with mb_substr in the function translateTextField of the TranslationForm.

🐛 Bug report
Status

Fixed

Version

2.1

Component

Code

Created by

🇵🇹Portugal joao.lemos

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024