mirror of
https://github.com/phpbb/phpbb.git
synced 2025-02-26 04:52:36 +01:00
Merge pull request #4209 from marc1706/ticket/14523
[ticket/14523] Replace prototype definition with shared services
This commit is contained in:
commit
b0fe454163
@ -161,7 +161,7 @@ services:
|
||||
|
||||
version_helper:
|
||||
class: phpbb\version_helper
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@cache'
|
||||
- '@config'
|
||||
|
@ -1,7 +1,7 @@
|
||||
services:
|
||||
attachment.delete:
|
||||
class: phpbb\attachment\delete
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@config'
|
||||
- '@dbal.conn'
|
||||
@ -12,7 +12,7 @@ services:
|
||||
|
||||
attachment.manager:
|
||||
class: phpbb\attachment\manager
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@attachment.delete'
|
||||
- '@attachment.resync'
|
||||
@ -20,13 +20,13 @@ services:
|
||||
|
||||
attachment.resync:
|
||||
class: phpbb\attachment\resync
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@dbal.conn'
|
||||
|
||||
attachment.upload:
|
||||
class: phpbb\attachment\upload
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@auth'
|
||||
- '@cache'
|
||||
|
@ -6,7 +6,7 @@ services:
|
||||
- '@captcha.plugins.service_collection'
|
||||
|
||||
# ----- Captcha plugins -----
|
||||
# Scope MUST be prototype for all the plugins to work.
|
||||
# Service MUST NOT be shared for all the plugins to work.
|
||||
captcha.plugins.service_collection:
|
||||
class: phpbb\di\service_collection
|
||||
arguments:
|
||||
@ -16,7 +16,7 @@ services:
|
||||
|
||||
core.captcha.plugins.gd:
|
||||
class: phpbb\captcha\plugins\gd
|
||||
scope: prototype
|
||||
shared: false
|
||||
calls:
|
||||
- [set_name, [core.captcha.plugins.gd]]
|
||||
tags:
|
||||
@ -24,7 +24,7 @@ services:
|
||||
|
||||
core.captcha.plugins.gd_wave:
|
||||
class: phpbb\captcha\plugins\gd_wave
|
||||
scope: prototype
|
||||
shared: false
|
||||
calls:
|
||||
- [set_name, [core.captcha.plugins.gd_wave]]
|
||||
tags:
|
||||
@ -32,7 +32,7 @@ services:
|
||||
|
||||
core.captcha.plugins.nogd:
|
||||
class: phpbb\captcha\plugins\nogd
|
||||
scope: prototype
|
||||
shared: false
|
||||
calls:
|
||||
- [set_name, [core.captcha.plugins.nogd]]
|
||||
tags:
|
||||
@ -40,7 +40,7 @@ services:
|
||||
|
||||
core.captcha.plugins.qa:
|
||||
class: phpbb\captcha\plugins\qa
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%tables.captcha_qa_questions%'
|
||||
- '%tables.captcha_qa_answers%'
|
||||
@ -52,7 +52,7 @@ services:
|
||||
|
||||
core.captcha.plugins.recaptcha:
|
||||
class: phpbb\captcha\plugins\recaptcha
|
||||
scope: prototype
|
||||
shared: false
|
||||
calls:
|
||||
- [set_name, [core.captcha.plugins.recaptcha]]
|
||||
tags:
|
||||
|
@ -31,10 +31,10 @@ services:
|
||||
factory: ['@dbal.extractor.factory', get]
|
||||
|
||||
# ----- DB Extractors for different drivers -----
|
||||
# Scope MUST be prototype for all the handlers to work correctly.
|
||||
# Service MUST NOT be shared for all the handlers to work correctly.
|
||||
dbal.extractor.extractors.mssql_extractor:
|
||||
class: phpbb\db\extractor\mssql_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
@ -42,7 +42,7 @@ services:
|
||||
|
||||
dbal.extractor.extractors.mysql_extractor:
|
||||
class: phpbb\db\extractor\mysql_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
@ -50,7 +50,7 @@ services:
|
||||
|
||||
dbal.extractor.extractors.oracle_extractor:
|
||||
class: phpbb\db\extractor\oracle_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
@ -58,7 +58,7 @@ services:
|
||||
|
||||
dbal.extractor.extractors.postgres_extractor:
|
||||
class: phpbb\db\extractor\postgres_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
@ -66,7 +66,7 @@ services:
|
||||
|
||||
dbal.extractor.extractors.sqlite3_extractor:
|
||||
class: phpbb\db\extractor\sqlite3_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
@ -74,7 +74,7 @@ services:
|
||||
|
||||
dbal.extractor.extractors.sqlite_extractor:
|
||||
class: phpbb\db\extractor\sqlite_extractor
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '%core.root_path%'
|
||||
- '@request'
|
||||
|
@ -23,7 +23,7 @@ services:
|
||||
|
||||
feed.forum:
|
||||
class: phpbb\feed\forum
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -36,7 +36,7 @@ services:
|
||||
|
||||
feed.forums:
|
||||
class: phpbb\feed\forums
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -49,7 +49,7 @@ services:
|
||||
|
||||
feed.news:
|
||||
class: phpbb\feed\news
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -62,7 +62,7 @@ services:
|
||||
|
||||
feed.overall:
|
||||
class: phpbb\feed\overall
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -75,7 +75,7 @@ services:
|
||||
|
||||
feed.topic:
|
||||
class: phpbb\feed\topic
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -88,7 +88,7 @@ services:
|
||||
|
||||
feed.topics:
|
||||
class: phpbb\feed\topics
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
@ -101,7 +101,7 @@ services:
|
||||
|
||||
feed.topics_active:
|
||||
class: phpbb\feed\topics_active
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@feed.helper'
|
||||
- '@config'
|
||||
|
@ -6,7 +6,7 @@ services:
|
||||
|
||||
files.filespec:
|
||||
class: phpbb\files\filespec
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@filesystem'
|
||||
- '@language'
|
||||
@ -18,7 +18,7 @@ services:
|
||||
|
||||
files.upload:
|
||||
class: phpbb\files\upload
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@filesystem'
|
||||
- '@files.factory'
|
||||
@ -28,7 +28,7 @@ services:
|
||||
|
||||
files.types.form:
|
||||
class: phpbb\files\types\form
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@files.factory'
|
||||
- '@language'
|
||||
@ -38,7 +38,7 @@ services:
|
||||
|
||||
files.types.local:
|
||||
class: phpbb\files\types\form
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@files.factory'
|
||||
- '@language'
|
||||
@ -47,7 +47,7 @@ services:
|
||||
|
||||
files.types.remote:
|
||||
class: phpbb\files\types\remote
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@config'
|
||||
- '@files.factory'
|
||||
|
@ -15,7 +15,7 @@ services:
|
||||
- '%tables.user_notifications%'
|
||||
|
||||
# ----- Notification's types -----
|
||||
# Scope MUST be prototype for all the plugins to work.
|
||||
# Service MUST NOT be shared for all the plugins to work.
|
||||
notification.type_collection:
|
||||
class: phpbb\di\service_collection
|
||||
arguments:
|
||||
@ -36,7 +36,7 @@ services:
|
||||
|
||||
notification.type.admin_activate_user:
|
||||
class: phpbb\notification\type\admin_activate_user
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
calls:
|
||||
- [set_user_loader, ['@user_loader']]
|
||||
@ -46,42 +46,42 @@ services:
|
||||
|
||||
notification.type.approve_post:
|
||||
class: phpbb\notification\type\approve_post
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.approve_topic:
|
||||
class: phpbb\notification\type\approve_topic
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.topic
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.bookmark:
|
||||
class: phpbb\notification\type\bookmark
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.disapprove_post:
|
||||
class: phpbb\notification\type\disapprove_post
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.disapprove_topic:
|
||||
class: phpbb\notification\type\disapprove_topic
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.topic
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.group_request:
|
||||
class: phpbb\notification\type\group_request
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
calls:
|
||||
- [set_user_loader, ['@user_loader']]
|
||||
@ -90,14 +90,14 @@ services:
|
||||
|
||||
notification.type.group_request_approved:
|
||||
class: phpbb\notification\type\group_request_approved
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.pm:
|
||||
class: phpbb\notification\type\pm
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
calls:
|
||||
- [set_user_loader, ['@user_loader']]
|
||||
@ -107,7 +107,7 @@ services:
|
||||
|
||||
notification.type.post:
|
||||
class: phpbb\notification\type\post
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
calls:
|
||||
- [set_user_loader, ['@user_loader']]
|
||||
@ -117,14 +117,14 @@ services:
|
||||
|
||||
notification.type.post_in_queue:
|
||||
class: phpbb\notification\type\post_in_queue
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.quote:
|
||||
class: phpbb\notification\type\quote
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
calls:
|
||||
- [set_utils, ['@text_formatter.utils']]
|
||||
@ -133,35 +133,35 @@ services:
|
||||
|
||||
notification.type.report_pm:
|
||||
class: phpbb\notification\type\report_pm
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.pm
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.report_pm_closed:
|
||||
class: phpbb\notification\type\report_pm_closed
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.pm
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.report_post:
|
||||
class: phpbb\notification\type\report_post
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.report_post_closed:
|
||||
class: phpbb\notification\type\report_post_closed
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.post
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
notification.type.topic:
|
||||
class: phpbb\notification\type\topic
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.base
|
||||
calls:
|
||||
- [set_user_loader, ['@user_loader']]
|
||||
@ -171,13 +171,13 @@ services:
|
||||
|
||||
notification.type.topic_in_queue:
|
||||
class: phpbb\notification\type\topic_in_queue
|
||||
scope: prototype
|
||||
shared: false
|
||||
parent: notification.type.topic
|
||||
tags:
|
||||
- { name: notification.type }
|
||||
|
||||
# ----- Notification's methods -----
|
||||
# Scope MUST be prototype for all the plugins to work.
|
||||
# Service MUST NOT be shared for all the plugins to work.
|
||||
notification.method_collection:
|
||||
class: phpbb\di\service_collection
|
||||
arguments:
|
||||
@ -187,7 +187,7 @@ services:
|
||||
|
||||
notification.method.board:
|
||||
class: phpbb\notification\method\board
|
||||
scope: prototype # scope MUST be prototype for this to work!
|
||||
shared: false
|
||||
arguments:
|
||||
- '@user_loader'
|
||||
- '@dbal.conn'
|
||||
@ -201,7 +201,7 @@ services:
|
||||
|
||||
notification.method.email:
|
||||
class: phpbb\notification\method\email
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@user_loader'
|
||||
- '@user'
|
||||
@ -213,7 +213,7 @@ services:
|
||||
|
||||
notification.method.jabber:
|
||||
class: phpbb\notification\method\jabber
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@user_loader'
|
||||
- '@user'
|
||||
|
@ -29,10 +29,10 @@ services:
|
||||
- '@user'
|
||||
|
||||
# ----- Report handlers -----
|
||||
# Scope MUST be prototype for all the handlers to work correctly.
|
||||
# Service MUST NOT be shared for all the handlers to work correctly.
|
||||
phpbb.report.handlers.report_handler_pm:
|
||||
class: phpbb\report\report_handler_pm
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@dbal.conn.driver'
|
||||
- '@dispatcher'
|
||||
@ -43,7 +43,7 @@ services:
|
||||
|
||||
phpbb.report.handlers.report_handler_post:
|
||||
class: phpbb\report\report_handler_post
|
||||
scope: prototype
|
||||
shared: false
|
||||
arguments:
|
||||
- '@dbal.conn.driver'
|
||||
- '@dispatcher'
|
||||
|
@ -13,7 +13,7 @@ services:
|
||||
|
||||
installer.navigation.main_navigation:
|
||||
class: phpbb\install\helper\navigation\main_navigation
|
||||
scope: prototype
|
||||
shared: false
|
||||
tags:
|
||||
- { name: installer.navigation }
|
||||
|
||||
@ -21,7 +21,7 @@ services:
|
||||
class: phpbb\install\helper\navigation\install_navigation
|
||||
arguments:
|
||||
- '@installer.helper.install_helper'
|
||||
scope: prototype
|
||||
shared: false
|
||||
tags:
|
||||
- { name: installer.navigation }
|
||||
|
||||
@ -29,7 +29,7 @@ services:
|
||||
class: phpbb\install\helper\navigation\update_navigation
|
||||
arguments:
|
||||
- '@installer.helper.install_helper'
|
||||
scope: prototype
|
||||
shared: false
|
||||
tags:
|
||||
- { name: installer.navigation }
|
||||
|
||||
@ -37,6 +37,6 @@ services:
|
||||
class: phpbb\install\helper\navigation\convertor_navigation
|
||||
arguments:
|
||||
- '@installer.helper.install_helper'
|
||||
scope: prototype
|
||||
shared: false
|
||||
tags:
|
||||
- { name: installer.navigation }
|
||||
|
Loading…
x
Reference in New Issue
Block a user