Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dynamic method calls in Queue.ts could fail with minification #3006

Closed
jeffposnick opened this issue Dec 22, 2021 · 0 comments · Fixed by #3012
Closed

Dynamic method calls in Queue.ts could fail with minification #3006

jeffposnick opened this issue Dec 22, 2021 · 0 comments · Fixed by #3012

Comments

@jeffposnick
Copy link
Contributor

There are some dynamic method calls in Queue.ts along the lines of:

await this._queueStore[`${operation}Entry`](entry);

(and a few more similar ones).

These method calls can fail if minification changes the names of the methods on the underlying QueueStore object.

I think it might be possible (via declare in TypeScript?) to give hints to various minifiers that they shouldn't do renaming, but honestly it might be easier just to use if()/else() conditionals to find the right method name to call, since there are usually only a couple to choose from for each code path.

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

Successfully merging a pull request may close this issue.

2 participants