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

[Bug] cancelLoadAll&cancelLoadImages #1747

Open
Gavin320 opened this issue Jan 14, 2025 · 0 comments
Open

[Bug] cancelLoadAll&cancelLoadImages #1747

Gavin320 opened this issue Jan 14, 2025 · 0 comments

Comments

@Gavin320
Copy link

Describe the Bug

An error occurred while canceling the loading of files being cached.
Error Details:
TypeError: Cannot read properties of undefined (reading 'additionalDetails')

Steps to Reproduce

  1. Start Caching Images,Here is the code:
    instance.imageIds.forEach((imageId, index) => { const options = { priority: 0, requestType: RequestType.Prefetch, additionalDetails: { imageId, index }, } as ImageLoaderOptions loadAndCacheImage(imageId, options).then(() => { instance.progress! += 1 }) })

3.When switching checks, attempt to cancel the previous requests by executing the following code:
cancelLoadAll()

The current behavior

An unknown exception occurred:Cannot read properties of undefined (reading 'additionalDetails')

The expected behavior

Execution successful

OS

windows10

Node version

2.14.11

Browser

chrome131

@Gavin320 Gavin320 changed the title [Bug] [Bug] cancelLoadAll&cancelLoadImages Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant