Skip to content
Snippets Groups Projects
Commit c8182dd5 authored by Ray Schamp's avatar Ray Schamp
Browse files

Use bowser[browser name] for detection

Also, fix detection of IE so it works. Apparently bowser.name !== 'IE' on IE with bowser. bowser.msie works though.
parent 317f11ed
No related branches found
No related tags found
No related merge requests found
......@@ -2,7 +2,7 @@ import StartAudioContext from 'startaudiocontext';
import bowser from 'bowser';
let AUDIO_CONTEXT;
if (bowser.name !== 'IE') {
if (!bowser.msie) {
AUDIO_CONTEXT = new (window.AudioContext || window.webkitAudioContext)();
StartAudioContext(AUDIO_CONTEXT);
......
......@@ -5,10 +5,9 @@ import bowser from 'bowser';
* @returns {boolean} False if the platform is definitely not supported.
*/
export default function () {
if (bowser.name === 'IE' ||
bowser.name === 'Opera' ||
bowser.name === 'Opera Mini' ||
bowser.name === 'Silk') {
if (bowser.msie ||
bowser.opera ||
bowser.silk) {
return false;
}
// @todo Should also test for versions of supported browsers
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment