Skip to content

Calling abort multiple times causes the abort event to be triggered multiple times #83

@mifi

Description

@mifi

This is not how it's supposed to work.

const { AbortController } = require('abortcontroller-polyfill/dist/cjs-ponyfill');

const a = new AbortController()
a.signal.addEventListener('abort', () => console.log('aborted'))
a.abort()
a.abort()

// outputs "aborted" twice

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions