Skip to content

Fix props output#253

Merged
alexandercerutti merged 1 commit intoalexandercerutti:masterfrom
gpoitch:gp/clone-fix
Oct 15, 2025
Merged

Fix props output#253
alexandercerutti merged 1 commit intoalexandercerutti:masterfrom
gpoitch:gp/clone-fix

Conversation

@gpoitch
Copy link
Copy Markdown
Contributor

@gpoitch gpoitch commented Sep 25, 2025

Description

Hi, great library!

This fixes an issue with the cloneRecursive utility function. It wasn't correctly handling arrays of primitives.

I encountered the issue when accessing pass.props, which we use to debug the resulting pass json without building the whole zip.

Fields such as:
preferredStyleSchemes: ['posterEventTicket', 'eventTicket']

were coming back as:
preferredStyleSchemes: [ { "0": "p", "1": "o", "2": "s", "3": "t", "4": "e", "5": "r", "6": "E", "7": "v", "8": "e", "9": "n", "10": "t", "11": "T", "12": "i", "13": "c", "14": "k", "15": "e", "16": "t" }, { "0": "e", "1": "v", "2": "e", "3": "n", "4": "t", "5": "T", "6": "i", "7": "c", "8": "k", "9": "e", "10": "t" } ]

Check relevant checkboxes

  • I've run tests (through npm test) and they passed
  • I generated a working Apple Wallet Pass after the change
  • Provided examples keep working after the change
  • This improvement is or might be a breaking change

Relevant information

@alexandercerutti
Copy link
Copy Markdown
Owner

alexandercerutti commented Sep 25, 2025

Hi @gpoitch! Thank you for your contribution and for using passkit-generator!

That's great, weird I've missed it.

Do you have any rush for this fix to land? Otherwise I would merge this in the v3.5.0, which will bring support to iOS 26 changes.

Let me know.

@gpoitch
Copy link
Copy Markdown
Contributor Author

gpoitch commented Sep 25, 2025

No rush. Thanks!

Copy link
Copy Markdown
Owner

@alexandercerutti alexandercerutti left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@alexandercerutti alexandercerutti merged commit 1e5760b into alexandercerutti:master Oct 15, 2025
1 of 3 checks passed
@alexandercerutti
Copy link
Copy Markdown
Owner

Published in v3.5.2 🎉 Thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants