mirror of
https://github.com/flarum/core.git
synced 2025-07-27 03:30:28 +02:00
Use one instance of formatter extender
This commit is contained in:
@@ -32,7 +32,9 @@ return [
|
|||||||
->css(__DIR__.'/less/forum.less'),
|
->css(__DIR__.'/less/forum.less'),
|
||||||
|
|
||||||
(new Extend\Formatter)
|
(new Extend\Formatter)
|
||||||
->configure(ConfigureMentions::class),
|
->configure(ConfigureMentions::class)
|
||||||
|
->render(Formatter\FormatPostMentions::class)
|
||||||
|
->render(Formatter\FormatUserMentions::class),
|
||||||
|
|
||||||
(new Extend\Model(Post::class))
|
(new Extend\Model(Post::class))
|
||||||
->belongsToMany('mentionedBy', Post::class, 'post_mentions_post', 'mentions_post_id', 'post_id')
|
->belongsToMany('mentionedBy', Post::class, 'post_mentions_post', 'mentions_post_id', 'post_id')
|
||||||
@@ -75,8 +77,4 @@ return [
|
|||||||
->listen(Hidden::class, Listener\UpdateMentionsMetadataWhenInvisible::class)
|
->listen(Hidden::class, Listener\UpdateMentionsMetadataWhenInvisible::class)
|
||||||
->listen(Deleted::class, Listener\UpdateMentionsMetadataWhenInvisible::class)
|
->listen(Deleted::class, Listener\UpdateMentionsMetadataWhenInvisible::class)
|
||||||
->listen(ConfigurePostsQuery::class, Listener\AddFilterByMentions::class),
|
->listen(ConfigurePostsQuery::class, Listener\AddFilterByMentions::class),
|
||||||
|
|
||||||
(new Extend\Formatter())
|
|
||||||
->render(Formatter\FormatPostMentions::class)
|
|
||||||
->render(Formatter\FormatUserMentions::class),
|
|
||||||
];
|
];
|
||||||
|
Reference in New Issue
Block a user