Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add shelve_personalization method to Sympa::List #1070

Closed
racke opened this issue Dec 29, 2020 · 0 comments · Fixed by #1141
Closed

Add shelve_personalization method to Sympa::List #1070

racke opened this issue Dec 29, 2020 · 0 comments · Fixed by #1141
Assignees
Labels
dry Don't repeat yourself enhancement ready A PR is waiting to be merged. Close to be solved Refactoring needed
Milestone

Comments

@racke
Copy link
Contributor

racke commented Dec 29, 2020

We are using blocks like the following in various parts of the code:


        # - Shelve personalization.
        if (    'on' eq ($list->{'admin'}{'personalization_feature'} || 'off')
            and 'none' ne
            ($list->{'admin'}{'personalization'}{'web_apply_on'} || 'none')) {
            $u_message->{shelved}{merge} =
                $list->{'admin'}{'personalization'}{'web_apply_on'};
        }

These blocks should be replaced by a call to a new method shelve_personalization in the list class.
It will take type as parameter (web or mail), shelves when appropriate and returns a true value if the message is going to be personalized.

@racke racke added this to the 6.2.62 milestone Dec 29, 2020
@racke racke self-assigned this Dec 29, 2020
@racke racke added the dry Don't repeat yourself label Dec 29, 2020
@ikedas ikedas added Refactoring needed dry Don't repeat yourself and removed dry Don't repeat yourself labels Dec 29, 2020
ikedas added a commit to ikedas/sympa that referenced this issue Apr 2, 2021
@ikedas ikedas added the ready A PR is waiting to be merged. Close to be solved label Apr 2, 2021
ikedas added a commit that referenced this issue Apr 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dry Don't repeat yourself enhancement ready A PR is waiting to be merged. Close to be solved Refactoring needed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants