Skip to content

armgit / orca

Public Imported from GitHub
0

Orca is the place for working with a fleet of agents (e.g. Grok Bot, Claude Code). Run any coding agent with your own subscription. Available on desktop, mobile and remote runtime.

486 B
Raw Blame
export function readNativeNotificationData(request: {
  content: { data?: unknown }
  trigger?: unknown
}): unknown {
  const trigger = request.trigger
  if (trigger && typeof trigger === 'object' && 'type' in trigger && trigger.type === 'push') {
    // Expo iOS keeps raw APNs custom fields here when content.data is null.
    if ('payload' in trigger && trigger.payload && typeof trigger.payload === 'object') {
      return trigger.payload
    }
  }
  return request.content.data
}