Skip to content

Fixes for #1324 #1326

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jul 13, 2025
Merged

Fixes for #1324 #1326

merged 3 commits into from
Jul 13, 2025

Conversation

neet
Copy link
Owner

@neet neet commented Jul 13, 2025

No description provided.

@Copilot Copilot AI review requested due to automatic review settings July 13, 2025 01:08
Copy link

size-limit report 📦

Path Size
rest 3.7 KB (0%)
streaming 3.7 KB (0%)
oauth 3.69 KB (0%)

Copy link

pkg-pr-new bot commented Jul 13, 2025

Open in StackBlitz

npm i https://pkg.pr.new/neet/masto.js/masto@1326

commit: 4817a7a

Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adjusts the handling of quote-related fields across several entities and ensures the quote field is included in the StatusEdit type.

  • Made quote, quotedStatusId, and quotedStatus properties optional in their respective interfaces
  • Modified StatusEdit to include the quote key in its Pick
  • Added exports for the new quote and shallow-quote modules in the index

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/mastodon/entities/v1/status.ts Made quote property optional in Status interface
src/mastodon/entities/v1/status-edit.ts Updated StatusEdit type to pick in the quote key
src/mastodon/entities/v1/shallow-quote.ts Made quotedStatusId optional in ShallowQuote interface
src/mastodon/entities/v1/quote.ts Made quotedStatus optional in Quote interface
src/mastodon/entities/v1/index.ts Added re-exports for quote and shallow-quote modules
Comments suppressed due to low confidence (4)

src/mastodon/entities/v1/status.ts:83

  • The JSDoc above should be updated to note that quote may now be omitted entirely in addition to being null.
  quote?: Quote | ShallowQuote | null;

src/mastodon/entities/v1/shallow-quote.ts:11

  • Update the comment to clarify that quotedStatusId can be undefined or null, not only null.
  quotedStatusId?: string | null;

src/mastodon/entities/v1/quote.ts:22

  • Adjust the doc comment to indicate that quotedStatus may be omitted or null when a quote is not accepted.
  quotedStatus?: Status | null;

src/mastodon/entities/v1/status.ts:83

  • Add or update unit tests to verify serialization and deserialization when the quote property is omitted, ensuring backward compatibility.
  quote?: Quote | ShallowQuote | null;

@neet neet merged commit e359327 into main Jul 13, 2025
7 checks passed
@neet neet deleted the follow-up-1324 branch July 13, 2025 01:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant