1
0
mirror of https://github.com/lancedikson/bowser synced 2024-10-27 20:34:22 +00:00

Fix iPhone and iPod detection

This commit is contained in:
Denis Demchenko 2017-06-09 23:49:08 +03:00
parent 45eec907e1
commit efce17881f

View File

@ -72,7 +72,11 @@ export default [
/* iPod/iPhone */
{
test: [/ipod|iphone/i],
test(parser) {
const iDevice = parser.test(/ipod|iphone/i);
const likeIDevice = parser.test(/like (ipod|iphone)/i);
return iDevice && !likeIDevice;
},
describe(ua) {
const model = getFirstMatch(/(ipod|iphone)/i, ua);
return {