Better slack alert validation

This commit is contained in:
James Cole
2023-09-16 08:44:20 +02:00
parent 7cf7c5fcef
commit 241ad25e2f
9 changed files with 13 additions and 19 deletions

View File

@@ -480,15 +480,16 @@ class User extends Authenticatable
if ($notification instanceof TestNotification) {
return app('fireflyconfig')->get('slack_webhook_url', '')->data;
}
if ($notification instanceof UserInvitation) {
return app('fireflyconfig')->get('slack_webhook_url', '')->data;
}
if ($notification instanceof UserRegistration) {
return app('fireflyconfig')->get('slack_webhook_url', '')->data;
}
if ($notification instanceof VersionCheckResult) {
return app('fireflyconfig')->get('slack_webhook_url', '')->data;
}
if ($notification instanceof UserInvitation) {
return app('fireflyconfig')->get('slack_webhook_url', '')->data;
}
return app('preferences')->getForUser($this, 'slack_webhook_url', '')->data;
}
@@ -598,7 +599,7 @@ class User extends Authenticatable
*/
public function userGroup(): BelongsTo
{
return $this->belongsTo(UserGroup::class, );
return $this->belongsTo(UserGroup::class,);
}
/**