* Validate file size against maximum limit * @throws {GitHubClientError} If file size exceeds limit
(relativePath: string, size: number)
| 69 | * @throws {GitHubClientError} If file size exceeds limit |
| 70 | */ |
| 71 | function validateFileSize(relativePath: string, size: number): void { |
| 72 | if (size > MAX_FILE_SIZE) { |
| 73 | throw new GitHubClientError( |
| 74 | `File "${relativePath}" exceeds maximum size limit (${(size / 1024 / 1024).toFixed(2)}MB > ${MAX_FILE_SIZE / 1024 / 1024}MB)`, |
| 75 | ); |
| 76 | } |
| 77 | } |
| 78 | |
| 79 | /** |
| 80 | * Result of feature conversion |
no outgoing calls
no test coverage detected
searching dependent graphs…