DispatchMe / meteor-deep-link

Handle deep linked data
MIT License
16 stars 6 forks source link

Can't get call backs to fire consistently #3

Open adamgins opened 8 years ago

adamgins commented 8 years ago

@raix Awesome plugin Thanks. Just having a few issues:

My iOS app opens when called with myapp://url but can't seem to get the all backs to fire consistently:

DeepLink.once('INTENT', function(intent){
        console.log('1 Got some deep linked data...',intent);
        alert("2:")
    });

    DeepLink.once('myapp', function(data, url, scheme, path, querystring){
        console.log('2 Got some deep linked data...',data, url, scheme, path, querystring);
        alert("3:" + url)
    });

If I shut down the app and then click link in Safari on iOS it opens and the call backs fire. If the app is already open, iOS switch to the app and opens it however the callbacks don't fire.

Any help appreciated

raix commented 8 years ago

Is this happening on meteor 1.3?

adamgins commented 8 years ago

Yes

Sent from my iPhone

On 21 Apr 2016, at 6:02 PM, Morten N.O. Nørgaard Henriksen notifications@github.com wrote:

Is this happening on meteor 1.3?

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub

mlecoq commented 8 years ago

@adamgins @raix I have a similar issue with the following stack trace

 I20160427-10:50:30.869(2)? 04-27 10:50:30.960  4075  4075 I chromium: [INFO:CONSOLE(386)] "Triggered by intent:", source: http://localhost:12120/packages/dispatch_deep-link.js?hash=e6aa87b3c8fe1e977610300bb1f89d9f2c94e2ff (386)
I20160427-10:50:30.886(2)? 04-27 10:50:30.991  4075  4075 I chromium: [INFO:CONSOLE(958)] "Exception in defer callback: TypeError: Cannot read property 'split' of undefined
I20160427-10:50:30.887(2)? 04-27 10:50:30.991  4075  4075 I chromium:     at parseQueryString (http://localhost:12120/packages/dispatch_deep-link.js?hash=e6aa87b3c8fe1e977610300bb1f89d9f2c94e2ff:131:36)
I20160427-10:50:30.887(2)? 04-27 10:50:30.991  4075  4075 I chromium:     at http://localhost:12120/packages/dispatch_deep-link.js?hash=e6aa87b3c8fe1e977610300bb1f89d9f2c94e2ff:408:18
I20160427-10:50:30.888(2)? 04-27 10:50:30.991  4075  4075 I chromium:     at _.extend.withValue (http://localhost:12120/packages/meteor.js?hash=0b0ea1099ba8153bbbc5fb555a755bdff3cec0c3:1105:17)
I20160427-10:50:30.889(2)? 04-27 10:50:30.991  4075  4075 I chromium:     at http://localhost:12120/packages/meteor.js?hash=0b0ea1099ba8153bbbc5fb555a755bdff3cec0c3:492:45
mlecoq commented 8 years ago

I have made a pull request

https://github.com/DispatchMe/meteor-deep-link/pull/4