videostream / cordova-chromecast

Chromecast running in Cordova
117 stars 58 forks source link

_routeListEl.classList.add not supported on older phones #10

Open marques99 opened 10 years ago

marques99 commented 10 years ago

On my old test phone running Andriod 2.3 does not have chrome install and the classList.add method is not available. Here is my fix. I do not use the route list method but this does resolve the error I am getting.

Replace in chrome.cast.js _routeListEl.classList.add('route-list');

With if(typeof _routeListEl.classList!='undefined') { _routeListEl.classList.add('route-list'); }else { _routeListEl.classList += 'route-list'; }