question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

cannot read property 'configureProvider' of undefined

See original GitHub issue

Hi, as I made reference to here https://github.com/fullstackreact/react-native-oauth/issues/14 I’m having an issue with the oath on Android. Do I need to configure the manager differently based on platform? At present my code looks like this

const manager = new OAuthManager('MyAPp');
const config = {
  facebook: {
    client_id: 'MY_CLIENT_ID',
    client_secret: 'MY_CLIENT_SECRET',
  },
};
manager.configure(config);

It works amazingly (Thanks @auser !!) on ios, but in android everything about the manager is then coming up as undefined. I removed all my promises handling etc to just strip it back to console logging the manager variable but I was getting 'cannot read property ‘configureProvider’ of undefined and it wouldn’t go any further.

Is this a bug or is this just user error? I (think) I;ve read the docs quite extensively and everything seems as it’s supposed to be? Cheers

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:1
  • Comments:28 (6 by maintainers)

github_iconTop GitHub Comments

7reactions
ozsirmacommented, Mar 1, 2017

I have the same problem in iOS.

react_native_debugger
4reactions
tendolukwagocommented, Jan 27, 2017

Hi @auser , I’m having the same “configureProvider is undefined” issue on iOS. I tried the react-native unlink and react-native link, as well, and that didn’t resolve the issue. I took a look at the set up you have in the demo link you referenced above and nothing is glaringly different. Here’s my set up:

componentWillMount(){
        const manager = new OAuthManager('my_app_name');

        const config =  {
            twitter: {
                consumer_key: 'my_consumer_key',
                consumer_secret: 'my_consumer_secret'
            },
            facebook: {
                client_id: 'my_client_id',
                client_secret: 'my_client_secret'
            }
        };
        manager.configure(config);
	this.manager = manager;
}
Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot update value in Kendo-grid - cannot read 'data ...
js:13 Uncaught TypeError: Cannot read property 'data' of undefined". What Did I wrong? < script > $(document).ready(function() ...
Read more >
nrwl-nx/community - Gitter
Ive added @nrwl/node but when i run nx g @nrwl/node:application appname all i get is Cannot read property 'types' of undefined . is...
Read more >
Models not working in Loopback Passport Module
TypeError: Cannot read property 'dataSource' of undefined at Array. (model.services.js:179) at Object.forEach (angular.js:323) at ...
Read more >
Configure Provider Search for Users - Salesforce Help
Uncaught TypeError: Cannot read properties of undefined (reading '$a') throws at ...
Read more >
https://www.jprog.com/wiki/GetFile.aspx?File=%2FDo...
17, 4164, A demogrpahics tab custom control set activated for Add Client ... in Form Designer an error occurs, "Cannot read property '0'...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found