This repository was archived by the owner on Jul 15, 2024. It is now read-only.
modify type definition of notifications/read according to the implementation#59
Open
yuchiki wants to merge 3 commits intomisskey-dev:developfrom
Open
modify type definition of notifications/read according to the implementation#59yuchiki wants to merge 3 commits intomisskey-dev:developfrom
yuchiki wants to merge 3 commits intomisskey-dev:developfrom
Conversation
2 tasks
yuchiki
commented
Mar 29, 2023
| 'notifications/create': { req: { body: string; header?: string | null; icon?: string | null; }; res: null; }; | ||
| 'notifications/mark-all-as-read': { req: NoParams; res: null; }; | ||
| 'notifications/read': { req: { notificationId: Notification['id']; }; res: null; }; | ||
| 'notifications/read': { req: { notificationIds: Notification['id'][]; }; res: null; }; |
Author
There was a problem hiding this comment.
notificationIds: Notification['id'][],
Member
There was a problem hiding this comment.
Author
There was a problem hiding this comment.
理解しました。
そちらがmergeされたらhttps://github.com/misskey-dev/misskey/pull/10331 の中で修正します!
Author
|
misskey-dev/misskey#10331 の中で、 node_modules/misskey-js/built/api.types.d.ts を直接↑の内容に書き換えた状態で , sw ディレクトリの中で |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix #60
What
The titile says:
Why
notifications/read's parameter was changed from an ID to a list of IDs.
https://github.com/misskey-dev/misskey/blob/42833cd9219cb8f5abd1756aa1c57b024b125710/packages/backend/src/core/NotificationService.ts#L27
But the type definition does not follow the change.
This type is used in packages/sw/, but this package is not typechecked in CI now
https://github.com/misskey-dev/misskey/blob/develop/packages/sw/src/scripts/notification-read.ts#L42
Additional info (optional)
N/A