Skip to content

Conversation

@crazytonyli
Copy link
Contributor

Description

The "sync" functions in PostService are only used in the Menu feature. This PR renames the PostService type to MenuPostService to avoid the sync function being used in other features. The sync functions fetch every single page when used to fetch pages, and fetch paginated posts when used to fetch posts, which I think is not something we'd normally want.

@crazytonyli crazytonyli added this to the 26.6 milestone Dec 8, 2025
@crazytonyli crazytonyli requested review from jkmassel and kean December 8, 2025 10:22
@crazytonyli crazytonyli enabled auto-merge December 8, 2025 10:22
@crazytonyli crazytonyli changed the title Move post service to menu Rename PostService to MenuPostService Dec 8, 2025
@sonarqubecloud
Copy link

sonarqubecloud bot commented Dec 8, 2025

@wpmobilebot
Copy link
Contributor

App Icon📲 You can test the changes from this Pull Request in Jetpack by scanning the QR code below to install the corresponding build.
App NameJetpack
ConfigurationRelease-Alpha
Build Number30083
VersionPR #25049
Bundle IDcom.jetpack.alpha
Commitec4110c
Installation URL1bfemv8lk4hg8
Automatticians: You can use our internal self-serve MC tool to give yourself access to those builds if needed.

@wpmobilebot
Copy link
Contributor

App Icon📲 You can test the changes from this Pull Request in WordPress by scanning the QR code below to install the corresponding build.
App NameWordPress
ConfigurationRelease-Alpha
Build Number30083
VersionPR #25049
Bundle IDorg.wordpress.alpha
Commitec4110c
Installation URL2h3q7fsu05h00
Automatticians: You can use our internal self-serve MC tool to give yourself access to those builds if needed.

Copy link
Contributor

@kean kean left a comment

Choose a reason for hiding this comment

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

The sync functions fetch every single page when used to fetch pages, and fetch paginated posts when used to fetch posts, which I think is not something we'd normally want.

Definitely not.

The Menu* code is something I would suggest to keep as Objective-C potentially indefinitely unless there is a need to redesign it.

@crazytonyli crazytonyli added this pull request to the merge queue Dec 8, 2025
Merged via the queue into trunk with commit 8fba54b Dec 8, 2025
28 of 34 checks passed
@crazytonyli crazytonyli deleted the move-post-service-to-menu branch December 8, 2025 21:56
@crazytonyli
Copy link
Contributor Author

The Menu* code is something I would suggest to keep as Objective-C

Yeah, I don't plan to change that part. It's rarely updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants