-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
Using Modal Dialogs - undefined error in canary #10416
Comments
I noticed the same problem in my Selenium tests this morning. I didn't have time to debug so I went back to beta1 which fixed the problem. |
Thanks @ilkkao - I guess the team is aware of the problem? |
@ef4 this may be related to the recent outlet fixes/refactoring |
I just bisected the problem to #10372 In my case I use modals exactly as instructed here: http://emberjs.com/guides/cookbook/user_interface_and_interaction/using_modal_dialogs/ Maybe the example from there can be upgraded to use canary version to demonstrate the problem? |
Wasn't too hard. Demo here: http://emberjs.jsbin.com/dupufilora/1/edit?html,js,output Click 'change name' to see the error. |
This is a duplicate of #10427 |
The error is being thrown from: ember-routing/lib/system/route.js. Basically, when rendering into an outlet in the @ef4 - Should we just guard against this ( |
Just adding a guard should be sufficient. I can work on it tonight if nobody gets to it first. We should also make sure we add a regression test for this case. |
The fix works for opening modals, but this: closeModal: function() {
return this.disconnectOutlet({
outlet: 'modal',
parentView: 'application'
});
} now yields: Uncaught TypeError: Cannot read property 'routeName' of undefined |
This resolves the secondary issue reported in [a comment](emberjs#10416 (comment)) on issue emberjs#10416.
@iamjstates I just submitted another PR that takes care of disconnection too. Thanks for being a beta tester. I've added all these scenarios to the integration tests so we never break these behaviors on people again. |
@ef4 - No worries, glad to help out in anyway. |
This resolves the secondary issue reported in [a comment](#10416 (comment)) on issue #10416.
In canary the below code does not work and yields the following error:
Uncaught TypeError: Cannot read property 'routeName' of undefined
It points to *return this.render(modalName, *
The text was updated successfully, but these errors were encountered: