Do not override the creator_id with the current logged user if the task is imported

Fixes #5345
This commit is contained in:
Frédéric Guillot
2023-09-22 20:39:46 -07:00
committed by Frédéric Guillot
parent 4d9e108f45
commit b02133982a
2 changed files with 31 additions and 4 deletions

View File

@@ -78,7 +78,8 @@ class TaskCreationModel extends Base
$values['title'] = t('Untitled');
}
if ($this->userSession->isLogged()) {
// Note: Do not override the creator_id if the task is imported
if (empty($values['creator_id']) && $this->userSession->isLogged()) {
$values['creator_id'] = $this->userSession->getId();
}