(validator: Validator)
| 1161 | } |
| 1162 | |
| 1163 | function serviceNameFor(validator: Validator): string | undefined { |
| 1164 | let shape = shapeOf(validator); |
| 1165 | if (shape?.kind === "lazy") return serviceNameFor(shape.thunk()); |
| 1166 | if (shape?.kind !== "stub") return undefined; |
| 1167 | return shape.service?.serviceName; |
| 1168 | } |
| 1169 | |
| 1170 | // True for a stub whose service surface could not be resolved. Pipelined |
| 1171 | // access on it can't be checked, so the runtime passes it through. |