diff --git a/application/Espo/Core/Export/Xlsx.php b/application/Espo/Core/Export/Xlsx.php index abacda6eb5..a947efe010 100644 --- a/application/Espo/Core/Export/Xlsx.php +++ b/application/Espo/Core/Export/Xlsx.php @@ -137,6 +137,8 @@ class Xlsx extends \Espo\Core\Injectable foreach ($badCharList as $badChar) { $sheetName = str_replace($badCharList, ' ', $sheetName); } + $sheetName = str_replace('\'', '', $sheetName); + $sheet->setTitle($sheetName); $fieldList = $params['fieldList']; diff --git a/application/Espo/Hooks/Note/Mentions.php b/application/Espo/Hooks/Note/Mentions.php index dd7c130596..206ce2fd08 100644 --- a/application/Espo/Hooks/Note/Mentions.php +++ b/application/Espo/Hooks/Note/Mentions.php @@ -61,12 +61,10 @@ class Mentions extends \Espo\Core\Hooks\Base } } - preg_match_all('/(@\w+)/', $post, $matches); + preg_match_all('/(@[\w@.-]+)/', $post, $matches); $mentionCount = 0; - - if (is_array($matches) && !empty($matches[0]) && is_array($matches[0])) { $parent = null; if ($entity->get('parentId') && $entity->get('parentType')) {