LimeSurvey: 3.x-LTS 4882e9f4

Author Committer Branch Timestamp Parent
gabrieljenik GitHub 3.x-LTS 2020-12-12 15:08:40 3.x-LTS b43652b3
Affected Issues  16854: Cannot attach PDF to email invitation (email template for surveys)
Changeset

Fixed issue 16854: Cannot attach PDF to email invitation (email template for surveys) (#1679)

  • Fixed issue 16854: Cannot attach PDF to email invitation (email template for surveys)

Previously, at emailtemplates controller's 'update' method, the settings were saved directly using updateAll. After commit '2c8ccdd5', in order to apply the model's validation, the settings are saved using 'setAttributes($attributes)' and 'save()'.
The setAttributes method, by default, only assigns 'safe' attributes (attributes that have a validation rule). That excludes the 'attachments' attribute.
Passing 'false' as second parameter solves the issue.

  • Fixed issue 16854: Cannot attach PDF to email invitation (email template for surveys)

Adding validation to attachments as to make them a safe attribute

mod - application/models/SurveyLanguageSetting.php Diff File