Forum Discussion
JavaScript errors in Custom connector
Thank you for reply.
The datasource I'm connecting to supports OAuth2.
As I wrote above the connector works fine and authorization process completes successfull.
Just the auth page includes a javascript that contains an error and I see the message about that error.
I've made a little research and found out the Power BI desktop uses its own browser so I can't disable running javascript using standard setting of IE.
Any ideas?
Cheers,
Alex.
First things first: you've exposed your client_id in a public forum, which is a major security vulnerability for your app. Before you do anything, I suggest you regenerate a new client_id and client_secret from the Vend developer console and update your app with those new values.
Second, do not disable running JavaScript; the whole OAuth authentication process relies on it.
You're experiencing a bug on the Vend sign-in page. My guess is that the Vend developers haven't fully tested the sign-in page on older browsers. Power BI uses the internal browser that comes shipped with your version of Windows. I'm on a Windows 10 machine through an Azure VM and the version Power BI is using is:
Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 6.2; Win64; x64; Trident/7.0; .NET4.0C; .NET4.0E)
You can check which browser version Power BI is using by running the following Power Query M script:
let
Source = Web.Page("<script>document.write(navigator.userAgent);</script>")[Data]{0}[Children]{0}[Children]{1}[Text]{0}
in
Source
I suggest contacting Vend and letting them know about this JavaScript error. Let them know what browser version you're using, which again, is the output of the query above. Hopefully, they'll appreciate your input and fix it quickly.