feat: validate from uploaded file #4933
Annotations
3 errors and 1 warning
Run coding standards check:
lib/Controller/FileController.php#L120
lib/Controller/FileController.php:120:13: InvalidReturnType: The declared return type 'OCP\AppFramework\Http\DataResponse<200|400|404, array{action?: int, created_at?: string, errors?: array<array-key, string>, file?: string, messages?: array<array-key, array{message: string, type: string}>, name?: string, nodeId?: int<0, max>, pdfVersion?: string, requested_by?: array{displayName: string, userId: string}, settings?: array{canRequestSign: bool, canSign: bool, hasSignatureFile?: bool, identificationDocumentsWaitingApproval?: bool, needIdentificationDocuments?: bool, phoneNumber: string, signerFileUuid: null|string}, signers?: array<array-key, array{description: null|string, displayName: string, email?: string, identifyMethods?: array<array-key, array{mandatory: int<0, max>, method: 'account'|'email', value: string}>, me: bool, notify?: array<array-key, array{date: int, method: 'activity'|'mail'|'notify'}>, remote_address?: string, request_sign_date: string, signRequestId: int<0, max>, sign_date?: null|string, sign_uuid?: string, signatureMethods?: array{clickToSign?: array{enabled: bool, label: string, name: string}, emailToken?: array{blurredEmail: string, hasConfirmCode: bool, hashOfEmail: string, identifyMethod: 'account'|'email', label: string, needCode: bool}, password?: array{hasSignatureFile: bool, label: string, name: string}}, signed: null|string, userId?: string, user_agent?: string, visibleElements?: array<array-key, array{coordinates: array{height?: int<0, max>, left?: int<0, max>, llx?: int<0, max>, lly?: int<0, max>, page?: int<0, max>, top?: int<0, max>, urx?: int<0, max>, ury?: int<0, max>, width?: int<0, max>}, elementId: int<0, max>, signRequestId: int<0, max>, type: string}>}>, size?: int<0, max>, status?: 0|1|2|3|4, statusText?: string, totalPages?: int<0, max>, url?: string, uuid?: string, visibleElements?: array<array-key, array{coordinates: array{height?: int<0, max>, left?: int<0, max>, llx?: int<0, max>, lly?: int<0, max>, page?: int<0, max>, top?: int<0, max>, urx?: int<0, max>, ury?: int<0, max>, width?: int<0, max>}, elementId: int<0, max>, signRequestId: int<0, max>, type: string}>}, array<never, never>>' for OCA\Libresign\Controller\FileController::validateBinary is incorrect, got 'OCP\AppFramework\Http\DataResponse<200|400|404, array{action?: 2000, created_at?: string, errors?: list{string}, file?: string, message?: string, messages?: array<array-key, array{message: string, type: 'info'}>, name?: string, nodeId?: int<0, max>, pdfVersion?: string, requested_by?: array{displayName: string, userId: string}, settings?: array{canRequestSign: bool, canSign: bool, hasSignatureFile?: bool, identificationDocumentsWaitingApproval?: bool, needIdentificationDocuments?: bool, phoneNumber: string, signerFileUuid: null|string}, signers?: array<array-key, array{description: null|string, displayName: string, email?: string, identifyMethods?: array<array-key, array{mandatory: int<0, max>, method: 'account'|'email', value: string}>, me: bool, notify?: array<array-key, array{date: int, method: 'activity'|'mail'|'notify'}>, remote_address?: string, request_sign_date: string, signRequestId: int<0, max>, sign_date?: null|string, sign_uuid?: string, signatureMethods?: array{clickToSign?: array{enabled: bool, label: string, name: string}, emailToken?: array{blurredEmail: string, hasConfirmCode: bool, hashOfEmail: string, identifyMethod: 'account'|'email', label: string, needCode: bool}, password?: array{hasSignatureFile: bool, label: string, name: string}}, signed: null|string, userId?: string, user_agent?: string, visibleElements?: array<array-key, array{coordinates: array{height?: int<0, max>, left?: int<0, max>, llx?: int<0, max>, lly?: int<0, max>, page?: int<0, max>, top?: int<0, max>, urx?: int<0, max>, ury?: int<0, max>, width?: int<0, max>}, elementId: int<0, max>, signRequestId: int<0, max>, type: string}>}>, size?: int<0, max>, status?: 0|1|2|3|4, statusText?: string, totalPages?: int<0, max>, url?: string, uuid?: string, visibleElements?: array<array-key, array{coordinates: array{height?: int<0, max>, lef
|
Run coding standards check:
lib/Controller/FileController.php#L1
lib/Controller/FileController.php:0:0: UnusedBaselineEntry: Baseline for issue "InvalidReturnType" has 1 extra entry. (see https://psalm.dev/316)
|
Run coding standards check
Process completed with exit code 2.
|
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
|
Loading