Skip to content

Commit 0feb1e3

Browse files
committed
fix: type errors
1 parent d535818 commit 0feb1e3

File tree

12 files changed

+12
-12
lines changed

12 files changed

+12
-12
lines changed

src/commands/history.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ BnC6gN0_TfStV2KKmPPXeg Welcome to your team's workspace null C
4242
})
4343
} catch (e) {
4444
this.log('Fetch history failed')
45-
this.error(e)
45+
this.error(e as Error)
4646
}
4747
}
4848
}

src/commands/login.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Login successfully
2424
this.log('Login successfully')
2525
} catch (err) {
2626
this.log('Login failed')
27-
this.error(err)
27+
this.error(err as Error)
2828
}
2929
}
3030
}

src/commands/notes/create.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ raUuSTetT5uQbqQfLnz9lA A new note gvfz2UB5THiKABQJQnLs6Q
6262
})
6363
} catch (e) {
6464
this.log('Create note failed')
65-
this.error(e)
65+
this.error(e as Error)
6666
}
6767
}
6868
}

src/commands/notes/delete.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export default class Delete extends HackMDCommand {
2828
await APIClient.deleteNote(noteId)
2929
} catch (e) {
3030
this.log('Delete note failed')
31-
this.error(e)
31+
this.error(e as Error)
3232
}
3333
}
3434
}

src/commands/notes/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ raUuSTetT5uQbqQfLnz9lA CLI test note gvfz2UB5THiKABQJQnLs6Q n
4343
})
4444
} catch (e) {
4545
this.log('Fetch user notes failed')
46-
this.error(e)
46+
this.error(e as Error)
4747
}
4848
}
4949
}

src/commands/notes/update.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ export default class Update extends HackMDCommand {
2929
await APIClient.updateNoteContent(noteId, content)
3030
} catch (e) {
3131
this.log('Update note content failed')
32-
this.error(e)
32+
this.error(e as Error)
3333
}
3434
}
3535
}

src/commands/team-notes/create.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ raUuSTetT5uQbqQfLnz9lA A new note gvfz2UB5THiKABQJQnLs6Q n
6767
})
6868
} catch (e) {
6969
this.log('Create team note failed')
70-
this.error(e)
70+
this.error(e as Error)
7171
}
7272
}
7373
}

src/commands/team-notes/delete.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ export default class Delete extends HackMDCommand {
3333
await APIClient.deleteTeamNote(teamPath, noteId)
3434
} catch (e) {
3535
this.log('Delete team note failed')
36-
this.error(e)
36+
this.error(e as Error)
3737
}
3838
}
3939
}

src/commands/team-notes/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ BnC6gN0_TfStV2KKmPPXeg Welcome to your team's workspace null CLI-test`,
4848
})
4949
} catch (e) {
5050
this.log('Fetch team notes failed')
51-
this.error(e)
51+
this.error(e as Error)
5252
}
5353
}
5454
}

src/commands/team-notes/update.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export default class Update extends HackMDCommand {
3434
await APIClient.updateTeamNoteContent(teamPath, noteId, content)
3535
} catch (e) {
3636
this.log('Update team note content failed')
37-
this.error(e)
37+
this.error(e as Error)
3838
}
3939
}
4040
}

0 commit comments

Comments
 (0)