Giter Site home page Giter Site logo

Comments (5)

timotree3 avatar timotree3 commented on June 25, 2024

I am guessing the exception is on this line

const fn = this.methods[method];

from cross-origin-message-bus.

timotree3 avatar timotree3 commented on June 25, 2024

I don't think the exception can come from the destructuring assignment you linked because in Chromium, destructuring undefined gives:

Uncaught TypeError: undefined is not iterable (cannot read property Symbol(Symbol.iterator))

and indexing undefined gives

Uncaught TypeError: Cannot read property '0' of undefined

from cross-origin-message-bus.

guillemcordoba avatar guillemcordoba commented on June 25, 2024

Hum this is interesting... This is the actual executing minified js:

                        child.on('response', function (data) {
                            var k = data[0], v = data[1];
                            // log.info("Received response for msg_id:", k );
                            var _a = _this.responses[k], f = _a[0], r = _a[1];
                            if (v instanceof Error)
                                r(v);
                            else
                                f(v);
                            delete _this.responses[k];

And I thought that the data[0] was the problem.

from cross-origin-message-bus.

timotree3 avatar timotree3 commented on June 25, 2024

Gotcha. That seems to imply that .emit("response", undefined) is called on a ParentAPI somewhere, but every single instance of "response" is accompanied by an array of length 2. I don't see how this error could possibly be happening

from cross-origin-message-bus.

guillemcordoba avatar guillemcordoba commented on June 25, 2024

Yeah I don't know... I did a console.log on data and it never showed undefined. But still this is what I'm getting... Let's see if others get the same when this becomes more used.

from cross-origin-message-bus.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.