MCPcopy
hub / github.com/anomalyco/opencode / isActiveOrgChoice

Function isActiveOrgChoice

packages/opencode/src/cli/cmd/account.ts:36–39  ·  view source on GitHub ↗
(
  active: Option.Option<{ id: AccountID; active_org_id: OrgID | null }>,
  choice: { accountID: AccountID; orgID: OrgID },
)

Source from the content-addressed store, hash-verified

34}
35
36const isActiveOrgChoice = (
37 active: Option.Option<{ id: AccountID; active_org_id: OrgID | null }>,
38 choice: { accountID: AccountID; orgID: OrgID },
39) => Option.isSome(active) && active.value.id === choice.accountID && active.value.active_org_id === choice.orgID
40
41const loginEffect = Effect.fn("login")(function* (url: string) {
42 const service = yield* Account.Service

Callers 1

account.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected