nrikiji / cordova-line-login-plugin

A cordova plugin for easy implementation of LINE login using LineSDK.
Apache License 2.0
21 stars 23 forks source link

Login function not returning the success or failed response #68

Closed h123eranga closed 3 years ago

h123eranga commented 3 years ago
  1. Is this compatible with ionic-angular 3.9.*?
  2. The plugins works fine for ionic 5 but it doesn't return anything for ionic 3
  3. Simply no response on login api call.

Showing the loading and the Line Verification screen to Allow permission. Finally, Showing a Toast message saying "Login Successful!" but no response in the promise.

Following are the dependencies. "@ionic-native/line-login": "^4.20.0", "cordova-line-login-plugin": "^1.2.11", "ionic-angular": "3.9.9", or "ionic-angular": "3.9.2",

dhaneshgosai commented 3 years ago

I am also facing same issue.

Its not returning user details and simply show a toast message "Login Successfully".

How to get userID & Display name in call back?

Please help us here on ionic 3.

Thanks in advance!

nrikiji commented 3 years ago

fix.

ionic-native may not be available in ionic3, so I solved it by calling the cordova plugin directly.

h123eranga commented 3 years ago

Thanks @nrikiji and following is a sample code works for ionic 3

declare` var lineLogin:any;

lineLogin.initialize({channel_id: "***"});

lineLogin.login((result) => { console.log( result.userID); console.log( result.displayName); console.log( result.pictureURL); }, (error) => { console.log("error); });