mirror of
https://github.com/fluxerapp/fluxer
synced 2026-10-18 21:45:31 +09:00
fix(api): support int53 attachment sizes (#1261)
This commit is contained in:
1 parent
40d1e90a3c
commit
3a8ed1012f
22 files changed
+289
-89
No files matched your search
@@ -38,6 +38,7 @@ import type {IARMessageContext, IARSubmission} from '../../report/IReportReposit
|
||||
import type {ReportService} from '../../report/ReportService';
|
||||
import {getReportSearchService} from '../../SearchFactory';
|
||||
import type {UserChannelService} from '../../user/services/UserChannelService';
|
||||
import {assertSafeByteSize} from '../../utils/ByteSizeUtils';
|
||||
import type {AdminAuditService} from './AdminAuditService';
|
||||
|
||||
interface AdminReportServiceDeps {
|
||||
@@ -580,7 +581,7 @@ export class AdminReportService {
|
||||
content_type: attachment.content_type ?? null,
|
||||
width: attachment.width ?? null,
|
||||
height: attachment.height ?? null,
|
||||
size: attachment.size != null ? Number(attachment.size) : null,
|
||||
size: attachment.size != null ? assertSafeByteSize(attachment.size, 'admin report attachment size') : null,
|
||||
ncmec_status: attachmentStatusesById.get(attachment.attachment_id.toString())?.status ?? 'not_submitted',
|
||||
ncmec_report_id: attachmentStatusesById.get(attachment.attachment_id.toString())?.ncmec_report_id ?? null,
|
||||
ncmec_failure_reason: attachmentStatusesById.get(attachment.attachment_id.toString())?.failure_reason ?? null,
|
||||
|
||||
Reference in new issue
Block a user