Commit a08e669
committed
webservice: get_recording_url_list error handling
We need get_recording_url_list() to return an array of recordings. So
when the API gives us an error message that means "there are no
recordings", then we need to return an empty array (so that it matches).
If the API gives us an error message that means "there was a problem
when we tried to find the recordings", then we don't want to pretend
that we know how many recordings there are (so we allow other exception
types to bubble up). Finally, if there was no API error message, then we
should have an API response that we can use. However, the code is
written to assume that we know how the API response is structured. If
the code is in the structure that we expect, then use it. Otherwise, we
should throw our own "unexpected response structure" error message to
avoid returning incorrect information.1 parent ac668a7 commit a08e669
1 file changed
Lines changed: 15 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1135 | 1135 | | |
1136 | 1136 | | |
1137 | 1137 | | |
1138 | | - | |
1139 | 1138 | | |
1140 | | - | |
| 1139 | + | |
| 1140 | + | |
| 1141 | + | |
| 1142 | + | |
| 1143 | + | |
| 1144 | + | |
| 1145 | + | |
| 1146 | + | |
| 1147 | + | |
| 1148 | + | |
| 1149 | + | |
| 1150 | + | |
| 1151 | + | |
| 1152 | + | |
| 1153 | + | |
1141 | 1154 | | |
1142 | 1155 | | |
1143 | 1156 | | |
| |||
0 commit comments