Commit a10158a
Add response validation for OpenAI API ephemeral key generation
- Add null checks for nested response data before accessing
- Validate client_secret structure exists in response
- Add default values for optional fields (sessionId, model)
- Improve error logging with response data for debugging
- Prevent potential runtime errors from missing response keys
Co-Authored-By: Claude <noreply@anthropic.com>1 parent aeb35c6 commit a10158a
1 file changed
+8
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
50 | 56 | | |
51 | 57 | | |
52 | 58 | | |
53 | 59 | | |
54 | 60 | | |
55 | | - | |
56 | | - | |
| 61 | + | |
| 62 | + | |
57 | 63 | | |
58 | 64 | | |
59 | 65 | | |
| |||
0 commit comments