mirror of
https://github.com/classchartsapi/classcharts-api-js.git
synced 2026-05-14 19:59:37 +00:00
Require getLesson options argument
This commit is contained in:
parent
e5e445f0ba
commit
dc2258d9f8
2 changed files with 6 additions and 1 deletions
5
.changeset/cool-actors-attend.md
Normal file
5
.changeset/cool-actors-attend.md
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
"classcharts-api": patch
|
||||
---
|
||||
|
||||
Require getLesson options argument
|
||||
|
|
@ -244,7 +244,7 @@ export class BaseClient {
|
|||
* @param options GetLessonsOptions
|
||||
* @returns Array of lessons
|
||||
*/
|
||||
async getLessons(options?: GetLessonsOptions): Promise<LessonsResponse> {
|
||||
async getLessons(options: GetLessonsOptions): Promise<LessonsResponse> {
|
||||
if (!options?.date) throw new Error("No date specified");
|
||||
const params = new URLSearchParams();
|
||||
params.append("date", String(options?.date));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue