( options: CompactExecutionPayloadOptions, observedBytes: number )
| 48 | } |
| 49 | |
| 50 | function largeValueLimitError( |
| 51 | options: CompactExecutionPayloadOptions, |
| 52 | observedBytes: number |
| 53 | ): PayloadSizeLimitError { |
| 54 | return new PayloadSizeLimitError({ |
| 55 | label: options.rejectLargeValueLabel ?? 'Large execution value', |
| 56 | maxBytes: options.thresholdBytes ?? LARGE_VALUE_THRESHOLD_BYTES, |
| 57 | observedBytes, |
| 58 | }) |
| 59 | } |
| 60 | |
| 61 | function assertRejectSize(observedBytes: number, options: CompactExecutionPayloadOptions): void { |
| 62 | if (!options.rejectLargeValues) return |
no outgoing calls
no test coverage detected