2
0

Add optional OAuth application to reports (#30539)

This commit is contained in:
Emelia Smith
2024-07-16 15:23:08 +02:00
committed by GitHub
parent fa54b61216
commit aa88aca0ad
11 changed files with 47 additions and 3 deletions

View File

@@ -10,6 +10,7 @@ class ReportService < BaseService
@comment = options.delete(:comment).presence || ''
@category = options[:rule_ids].present? ? 'violation' : (options.delete(:category).presence || 'other')
@rule_ids = options.delete(:rule_ids).presence
@application = options.delete(:application).presence
@options = options
raise ActiveRecord::RecordNotFound if @target_account.unavailable?
@@ -35,7 +36,8 @@ class ReportService < BaseService
uri: @options[:uri],
forwarded: forward_to_origin?,
category: @category,
rule_ids: @rule_ids
rule_ids: @rule_ids,
application: @application
)
end