Skip to content

Commit 3306f13

Browse files
committed
Correct getRandom response type
Fixes #163
1 parent 8732ae3 commit 3306f13

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/methods/photos/index.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,10 @@ export const getRandom = {
6363
},
6464
}),
6565
),
66-
handleResponse: castResponse<Photo.Random>(),
66+
handleResponse: castResponse<
67+
// An array when the `count` query parameter is used.
68+
Photo.Random | Photo.Random[]
69+
>(),
6770
};
6871

6972
export const trackDownload = {

0 commit comments

Comments
 (0)