MCPcopy Index your code
hub / github.com/simstudioai/sim / resolveSyncMode

Function resolveSyncMode

apps/sim/connectors/x/x.ts:82–88  ·  view source on GitHub ↗

* Resolves the configured sync mode, defaulting to the authenticated user's * own posts.

(sourceConfig: Record<string, unknown>)

Source from the content-addressed store, hash-verified

80 * own posts.
81 */
82function resolveSyncMode(sourceConfig: Record<string, unknown>): SyncMode {
83 const mode = sourceConfig.syncMode
84 if (mode === 'user' || mode === 'mentions' || mode === 'bookmarks' || mode === 'likes') {
85 return mode
86 }
87 return 'me'
88}
89
90/**
91 * Reads a boolean toggle from a dropdown config field that stores 'true' / 'false'

Callers 1

x.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected