Skip to content
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

Never Authenticated Error on Device #34

Open
dev9163 opened this issue May 10, 2018 · 0 comments
Open

Never Authenticated Error on Device #34

dev9163 opened this issue May 10, 2018 · 0 comments

Comments

@dev9163
Copy link

dev9163 commented May 10, 2018

Hi,

I am trying to achieve deferred login in my app. I changed the should authenticate to false in bootconfig.json. I have also written the following code in the place I need to login:

let appId = <my_app_id>;
let loginURL = 'https://test.salesforce.com';
let oauthCallbackURL = 'http://localhost:8100/oauthcallback.html';
let oauth = OAuth.createInstance(appId, loginURL, oauthCallbackURL);

oauth.login().then((oauthData) => {
  DataService.createInstance(oauthData, { proxyURL: "https://dev-cors-proxy.herokuapp.com/" });
});

But, on running my app in the device, I get the following error:

TIMING com.salesforce.oauth:getAuthCredentials: 79.577ms plugins/com.salesforce/www/com.salesforce.util.exec.js:43 TIMING com.salesforce.oauth:getAuthCredentials failed vendor.js:52086 Never authenticated vendor.js:54803 EXCEPTION: Uncaught (in promise): Never authenticated vendor.js:54808 ORIGINAL STACKTRACE:vendor.js:54808 ErrorHandler.handleError vendor.js:54809 Error: Uncaught (in promise): Never authenticated at s (file:///android_asset/www/build/polyfills.js:3:8568) at s (file:///android_asset/www/build/polyfills.js:3:8391) at file:///android_asset/www/build/polyfills.js:3:8902 at t.invokeTask (file:///android_asset/www/build/polyfills.js:3:14051) at Object.inner.inner.fork.onInvokeTask (file:///android_asset/www/build/vendor.js:27523:37) at t.invokeTask (file:///android_asset/www/build/polyfills.js:3:14025) at e.runTask (file:///android_asset/www/build/polyfills.js:3:11411) at i (file:///android_asset/www/build/polyfills.js:3:8028) at u (file:///android_asset/www/build/polyfills.js:2:16275) at file:///android_asset/www/build/polyfills.js:2:16399vendor.js:54809 ErrorHandler.handleError

I am stuck in this for 3 weeks now. Can someone please help me in this?

I am using Ionic 2 and Angular 2. Salesforce Mobile SDK 6.1 (5.3 also has the same error)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant