Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion app/Livewire/Customer/Plugins/Show.php
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ public function submitForReview(): void
// Notify
$user->notify(new PluginSubmitted($this->plugin));

Notification::route('mail', config('mail.support_address'))
Notification::route('mail', [config('mail.support_address'), config('mail.marketplace_address')])
->notify(new PluginPendingReview($this->plugin));

Flux::toast(variant: 'success', text: 'Your plugin has been submitted for review!');
Expand Down
2 changes: 1 addition & 1 deletion app/Models/Plugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -1116,7 +1116,7 @@ public function messageAdmins(string $message, ?int $causerId = null): PluginAct
'causer_id' => $causerId ?? $this->user_id,
]);

Notification::route('mail', config('mail.support_address'))
Notification::route('mail', [config('mail.support_address'), config('mail.marketplace_address')])
->notify(new PluginDeveloperReplied($this, $activity));

return $activity;
Expand Down
13 changes: 13 additions & 0 deletions config/mail.php
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,19 @@

'support_address' => env('MAIL_SUPPORT_ADDRESS', 'support@nativephp.com'),

/*
|--------------------------------------------------------------------------
| Marketplace Address
|--------------------------------------------------------------------------
|
| The mailbox for the Marketplace team. Plugin review submissions and
| developer replies to review messages are sent here as well as to the
| support address.
|
*/

'marketplace_address' => env('MAIL_MARKETPLACE_ADDRESS', 'marketplace@nativephp.com'),

/*
|--------------------------------------------------------------------------
| Markdown Mail Settings
Expand Down
2 changes: 1 addition & 1 deletion tests/Feature/CustomerPluginReviewChecksTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ public function submitting_a_plugin_for_review_runs_review_checks(): void
Notification::assertSentOnDemand(
PluginPendingReview::class,
function (PluginPendingReview $notification, array $channels, object $notifiable) use ($plugin) {
return $notifiable->routes['mail'] === 'support@nativephp.com'
return $notifiable->routes['mail'] === ['support@nativephp.com', 'marketplace@nativephp.com']
&& $notification->plugin->id === $plugin->id;
}
);
Expand Down
2 changes: 1 addition & 1 deletion tests/Feature/Livewire/Customer/PluginMessagesTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ public function test_developer_can_reply_and_the_team_is_notified(): void

Notification::assertSentOnDemand(
PluginDeveloperReplied::class,
fn (PluginDeveloperReplied $notification, array $channels, object $notifiable) => $notifiable->routes['mail'] === 'support@nativephp.com'
fn (PluginDeveloperReplied $notification, array $channels, object $notifiable) => $notifiable->routes['mail'] === ['support@nativephp.com', 'marketplace@nativephp.com']
&& $notification->plugin->is($plugin)
&& $notification->activity->is($reply)
);
Expand Down
Loading