MCPcopy Index your code
hub / github.com/CodebuffAI/codebuff / isWeeklyLimitError

Function isWeeklyLimitError

packages/billing/src/subscription.ts:75–79  ·  view source on GitHub ↗
(
  result: BlockGrantResult,
)

Source from the content-addressed store, hash-verified

73export type BlockGrantResult = BlockGrant | WeeklyLimitError | BlockExhaustedError
74
75export function isWeeklyLimitError(
76 result: BlockGrantResult,
77): result is WeeklyLimitError {
78 return 'error' in result && result.error === 'weekly_limit_reached'
79}
80
81export function isBlockExhaustedError(
82 result: BlockGrantResult,

Callers 2

postChatCompletionsFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected