Skip to content

js-legacy: Import Buffer explicitly instead of relying on the global - #164

Open
Iamsohungrynow wants to merge 1 commit into
solana-program:mainfrom
Iamsohungrynow:fix/js-legacy-explicit-buffer
Open

Iamsohungrynow wants to merge 1 commit into
solana-program:mainfrom
Iamsohungrynow:fix/js-legacy-explicit-buffer

Conversation

@Iamsohungrynow

Copy link
Copy Markdown

same fix as solana-program/token-metadata#153, this repo was missed. without a global Buffer all four instruction builders throw ReferenceError: Buffer is not defined

@joncinque joncinque left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks for your contribution.

Note that Buffer is also used as a type in state/tokenGroup.ts and state/tokenGroupMember.ts, so if we really want to fix this, we should add import type { Buffer } from 'buffer'; to those files too

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