Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
a2d50a1
Style: Update constructor
tatevikg1 Dec 30, 2025
216978e
UserPersonalizer
tatevikg1 Dec 30, 2025
968044a
Use correct mailer
tatevikg1 Jan 2, 2026
78146e5
refactor
tatevikg1 Jan 4, 2026
975b418
RateLimitedCampaignMailer
tatevikg1 Jan 4, 2026
9b45ab3
PlaceholderValueResolverInterface
tatevikg1 Jan 7, 2026
8ed86ed
FORWARDEDBY
tatevikg1 Jan 8, 2026
5bed8e2
ForwardValueResolver
tatevikg1 Jan 8, 2026
5fdae5b
PreferencesValueResolver
tatevikg1 Jan 8, 2026
9d07526
SignatureValueResolver
tatevikg1 Jan 8, 2026
de8f4a8
MailConstructor
tatevikg1 Jan 8, 2026
54368f1
Append footer and signature if not prsent
tatevikg1 Jan 12, 2026
3728a1a
Rename UserPersonalizer to MessagePlaceholderProcessor
tatevikg1 Jan 12, 2026
988ff0c
PatternResolver registration
tatevikg1 Jan 12, 2026
6fa0137
UserTrackValueResolver
tatevikg1 Jan 12, 2026
026fedb
NormalizePlaceholderKey
tatevikg1 Jan 13, 2026
6823f07
UserDataSupportingResolver
tatevikg1 Jan 13, 2026
1a83a77
UserPersonalizer for SubscriptionConfirmationMessageHandler
tatevikg1 Jan 13, 2026
cbdb3b2
supportingResolvers
tatevikg1 Jan 13, 2026
9ac9cae
EmailBuilder
tatevikg1 Jan 14, 2026
10e5fa5
MailConstructorInterface
tatevikg1 Jan 14, 2026
51d5542
FooterValueResolver
tatevikg1 Jan 14, 2026
6a2ae3c
applyCampaignHeaders
tatevikg1 Jan 14, 2026
86f02a2
Add missing configs
tatevikg1 Jan 15, 2026
93e95e4
AttachmentAdder
tatevikg1 Jan 15, 2026
fc63fa4
applyContentAndFormatting
tatevikg1 Jan 16, 2026
89ba6df
Autowire, autoregister
tatevikg1 Jan 16, 2026
5fd4e4a
applyContentAndFormatting
tatevikg1 Jan 16, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@
"ext-libxml": "*",
"ext-gd": "*",
"ext-curl": "*",
"ext-fileinfo": "*"
"ext-fileinfo": "*",
"setasign/fpdf": "^1.8"
},
"require-dev": {
"phpunit/phpunit": "^9.5",
Expand Down
10 changes: 10 additions & 0 deletions config/parameters.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ parameters:
env(APP_DEV_EMAIL): '[email protected]'
app.powered_by_phplist: '%%env(APP_POWERED_BY_PHPLIST)%%'
env(APP_POWERED_BY_PHPLIST): '0'
app.preference_page_show_private_lists: '%%env(PREFERENCEPAGE_SHOW_PRIVATE_LISTS)%%'
env(PREFERENCEPAGE_SHOW_PRIVATE_LISTS): '0'
app.rest_api_domain: '%%env(REST_API_DOMAIN)%%'
env(REST_API_DOMAIN): 'https://example.com/api/v2'

# Email configuration
app.mailer_from: '%%env(MAILER_FROM)%%'
Expand Down Expand Up @@ -115,6 +119,12 @@ parameters:
env(EXTERNALIMAGE_TIMEOUT): '30'
messaging.external_image_max_size: '%%env(EXTERNALIMAGE_MAXSIZE)%%'
env(EXTERNALIMAGE_MAXSIZE): '204800'
messaging.forward_alternative_content: '%%env(FORWARD_ALTERNATIVE_CONTENT)%%'
env(FORWARD_ALTERNATIVE_CONTENT): '0'
messaging.email_text_credits: '%%env(EMAILTEXTCREDITS)%%'
env(EMAILTEXTCREDITS): '0'
messaging.always_add_user_track: '%%env(ALWAYS_ADD_USERTRACK)%%'
env(ALWAYS_ADD_USERTRACK): '1'

phplist.upload_images_dir: '%%env(PHPLIST_UPLOADIMAGES_DIR)%%'
env(PHPLIST_UPLOADIMAGES_DIR): 'images'
Expand Down
40 changes: 24 additions & 16 deletions config/services/builders.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,22 +4,30 @@ services:
autoconfigure: true
public: false

PhpList\Core\Domain\Messaging\Service\Builder\MessageBuilder:
autowire: true
autoconfigure: true
PhpList\Core\Domain\:
resource: '../../src/Domain/*/Service/Builder/*'

PhpList\Core\Domain\Messaging\Service\Builder\MessageFormatBuilder:
autowire: true
autoconfigure: true
# Concrete mail constructors
PhpList\Core\Domain\Messaging\Service\Constructor\SystemMailContentBuilder: ~
PhpList\Core\Domain\Messaging\Service\Constructor\CampaignMailContentBuilder: ~

PhpList\Core\Domain\Messaging\Service\Builder\MessageScheduleBuilder:
autowire: true
autoconfigure: true
# Two EmailBuilder services with different constructors injected
Core.EmailBuilder.system:
class: PhpList\Core\Domain\Messaging\Service\Builder\EmailBuilder
arguments:
$mailConstructor: '@PhpList\Core\Domain\Messaging\Service\Constructor\SystemMailContentBuilder'
$googleSenderId: '%messaging.google_sender_id%'
$useAmazonSes: '%messaging.use_amazon_ses%'
$usePrecedenceHeader: '%messaging.use_precedence_header%'
$devVersion: '%app.dev_version%'
$devEmail: '%app.dev_email%'

PhpList\Core\Domain\Messaging\Service\Builder\MessageContentBuilder:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Builder\MessageOptionsBuilder:
autowire: true
autoconfigure: true
Core.EmailBuilder.campaign:
class: PhpList\Core\Domain\Messaging\Service\Builder\EmailBuilder
arguments:
$mailConstructor: '@PhpList\Core\Domain\Messaging\Service\Constructor\CampaignMailContentBuilder'
$googleSenderId: '%messaging.google_sender_id%'
$useAmazonSes: '%messaging.use_amazon_ses%'
$usePrecedenceHeader: '%messaging.use_precedence_header%'
$devVersion: '%app.dev_version%'
$devEmail: '%app.dev_email%'
101 changes: 3 additions & 98 deletions config/services/managers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,53 +4,10 @@ services:
autoconfigure: true
public: false

PhpList\Core\Domain\Configuration\Service\Manager\ConfigManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Configuration\Service\Manager\EventLogManager:
autowire: true
autoconfigure: true
PhpList\Core\Domain\:
resource: '../../src/Domain/*/Service/Manager/*'

PhpList\Core\Domain\Identity\Service\SessionManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Identity\Service\AdministratorManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Identity\Service\AdminAttributeDefinitionManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Identity\Service\AdminAttributeManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Identity\Service\PasswordManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscriberManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscriberListManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscriptionManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\AttributeDefinitionManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\DynamicListAttrManager:
autowire: true
autoconfigure: true
PhpList\Core\Bounce\Service\Manager\BounceManager: ~

Doctrine\DBAL\Schema\AbstractSchemaManager:
factory: ['@doctrine.dbal.default_connection', 'createSchemaManager']
Expand All @@ -62,55 +19,3 @@ services:
arguments:
$dbPrefix: '%database_prefix%'
$dynamicListTablePrefix: '%list_table_prefix%'

PhpList\Core\Domain\Subscription\Service\Manager\SubscriberHistoryManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscriberAttributeManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscriberBlacklistManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Subscription\Service\Manager\SubscribePageManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\MessageManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\TemplateManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\TemplateImageManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\BounceRegexManager:
autowire: true
autoconfigure: true

PhpList\Core\Bounce\Service\Manager\BounceManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\ListMessageManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\BounceRuleManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\SendProcessManager:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Messaging\Service\Manager\MessageDataManager:
autowire: true
autoconfigure: true
31 changes: 3 additions & 28 deletions config/services/messenger.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,34 +5,9 @@ services:
resource: '../../src/Domain/Messaging/MessageHandler'
tags: [ 'messenger.message_handler' ]

PhpList\Core\Domain\Messaging\MessageHandler\SubscriberConfirmationMessageHandler:
autowire: true
autoconfigure: true
tags: [ 'messenger.message_handler' ]
arguments:
$confirmationUrl: '%app.confirmation_url%'

PhpList\Core\Domain\Messaging\MessageHandler\AsyncEmailMessageHandler:
autowire: true
autoconfigure: true
tags: [ 'messenger.message_handler' ]

PhpList\Core\Domain\Messaging\MessageHandler\PasswordResetMessageHandler:
autowire: true
autoconfigure: true
tags: [ 'messenger.message_handler' ]
arguments:
$passwordResetUrl: '%app.password_reset_url%'

PhpList\Core\Domain\Messaging\MessageHandler\SubscriptionConfirmationMessageHandler:
autowire: true
autoconfigure: true
tags: [ 'messenger.message_handler' ]

PhpList\Core\Domain\Messaging\MessageHandler\CampaignProcessorMessageHandler:
autowire: true

PhpList\Core\Domain\Subscription\MessageHandler\DynamicTableMessageHandler:
autowire: true
autoconfigure: true
tags: [ 'messenger.message_handler' ]
arguments:
$campaignEmailBuilder: '@Core.EmailBuilder.campaign'
$systemEmailBuilder: '@Core.EmailBuilder.system'
5 changes: 5 additions & 0 deletions config/services/parameters.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
parameters:
# Flattened parameters for direct DI usage (Symfony does not support dot access into arrays)
app.config.message_from_address: '[email protected]'
app.config.default_message_age: 15768000

# Keep original grouped array for legacy/config-provider usage
app.config:
message_from_address: '[email protected]'
admin_address: '[email protected]'
Expand Down
9 changes: 3 additions & 6 deletions config/services/providers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,6 @@ services:
arguments:
$config: '%app.config%'

PhpList\Core\Domain\Common\IspRestrictionsProvider:
autowire: true
autoconfigure: true
arguments:
$confPath: '%app.phplist_isp_conf_path%'

PhpList\Core\Domain\Subscription\Service\Provider\CheckboxGroupValueProvider:
autowire: true
PhpList\Core\Domain\Subscription\Service\Provider\SelectOrRadioValueProvider:
Expand All @@ -30,3 +24,6 @@ services:

PhpList\Core\Domain\Subscription\Service\Provider\SubscriberAttributeChangeSetProvider:
autowire: true

PhpList\Core\Domain\Common\IspRestrictionsProvider:
autowire: true
15 changes: 15 additions & 0 deletions config/services/repositories.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ services:
arguments:
- PhpList\Core\Domain\Configuration\Model\EventLog

PhpList\Core\Domain\Configuration\Repository\UrlCacheRepository:
parent: PhpList\Core\Domain\Common\Repository\AbstractRepository
arguments:
- PhpList\Core\Domain\Configuration\Model\UrlCache


PhpList\Core\Domain\Identity\Repository\AdministratorRepository:
parent: PhpList\Core\Domain\Common\Repository\AbstractRepository
Expand Down Expand Up @@ -145,3 +150,13 @@ services:
parent: PhpList\Core\Domain\Common\Repository\AbstractRepository
arguments:
- PhpList\Core\Domain\Messaging\Model\MessageData

PhpList\Core\Domain\Messaging\Repository\AttachmentRepository:
parent: PhpList\Core\Domain\Common\Repository\AbstractRepository
arguments:
- PhpList\Core\Domain\Messaging\Model\Attachment

PhpList\Core\Domain\Messaging\Repository\MessageAttachmentRepository:
parent: PhpList\Core\Domain\Common\Repository\AbstractRepository
arguments:
- PhpList\Core\Domain\Messaging\Model\MessageAttachment
24 changes: 24 additions & 0 deletions config/services/resolvers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,27 @@ services:
PhpList\Core\Bounce\Service\BounceActionResolver:
arguments:
- !tagged_iterator { tag: 'phplist.bounce_action_handler' }

PhpList\Core\Domain\Configuration\Service\Placeholder\UnsubscribeUrlValueResolver:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Configuration\Service\Placeholder\ConfirmationUrlValueResolver:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Configuration\Service\Placeholder\PreferencesUrlValueResolver:
autowire: true
autoconfigure: true

PhpList\Core\Domain\Configuration\Service\Placeholder\SubscribeUrlValueResolver:
autowire: true
autoconfigure: true

_instanceof:
PhpList\Core\Domain\Configuration\Service\Placeholder\PlaceholderValueResolverInterface:
tags: ['phplist.placeholder_resolver']
PhpList\Core\Domain\Configuration\Service\Placeholder\PatternValueResolverInterface:
tags: [ 'phplist.pattern_resolver' ]
PhpList\Core\Domain\Configuration\Service\Placeholder\SupportingPlaceholderResolverInterface:
tags: [ 'phplist.supporting_placeholder_resolver' ]
Loading
Loading