mirror of
https://github.com/TelegramMessenger/Telegram-iOS.git
synced 2026-05-21 18:20:41 +00:00
46566e7155
Applies the wave-11/12 AccountStateManager collapse pattern to SelectablePeerNode. Module is now fully Postbox-free (source + BUILD). - SelectablePeerNode.setup(... postbox: Postbox, network: Network, ...) -> setup(... stateManager: AccountStateManager, ...). Same for setupStoryRepost. AvatarNode.setPeer and EmojiStatusComponent are forwarded as stateManager.postbox / .network without naming Postbox. - Three Namespaces.Peer.SecretChat == checks rewritten to use the existing PeerId.isSecretChat extension (as in wave 13). - ShareControllerPeerGridItem.setup / setupStoryRepost and HorizontalPeerItem.setup call sites collapse to stateManager:. JoinLinkPreviewPeerContentNode uses the convenience setup(context: AccountContext) and is unchanged. - Drop import Postbox in SelectablePeerNode.swift and the //submodules/Postbox:Postbox dep in SelectablePeerNode/BUILD. The stateManager fallback (over the normally-preferred engine: TelegramEngine) is used because SelectablePeerNode crosses the Share Extension boundary: ShareControllerAccountContextExtension has no Account, so TelegramEngine(account:) is physically unreachable there. This matches the "rare but genuine fallback" clause of feedback_postbox_refactor_handle.md. Build verified green (debug_sim_arm64, 193 actions). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>