Skip to content
This repository was archived by the owner on Feb 26, 2024. It is now read-only.
This repository was archived by the owner on Feb 26, 2024. It is now read-only.

zones.js mangles XMLHttpRequest constants #127

@benweissmann

Description

@benweissmann

the patchClass() function doesn't copy over constants from the patched class. This means that a patched XMLHttpRequest won't have the constants XMLHttpRequest.DONE, etc. This breaks the common pattern of:

var req = new XMLHttpRequest();
req.onreadystatechange = function() {
    if (req.readyState === XMLHttpRequest.DONE) {
        // do something with the result
    }
};

patchClass() should copy over static properties of a class.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions