( view: Pick<QueuedStreakView, 'postId'>, )
| 63 | }; |
| 64 | |
| 65 | export const removeStreakView = ( |
| 66 | view: Pick<QueuedStreakView, 'postId'>, |
| 67 | ): void => { |
| 68 | writeStreakViewQueue( |
| 69 | readStreakViewQueue().filter((item) => !isSameView(item, view)), |
| 70 | ); |
| 71 | }; |
| 72 | |
| 73 | // Codes that mean the API will never count this view (the post is gone, the |
| 74 | // user cannot see it, or the session is not valid). Anything else, including |
no test coverage detected