mirror of
https://github.com/faisalman/ua-parser-js.git
synced 2025-09-28 00:18:45 +03:00
Merge pull request #18 from johnyanarella/master
Fixed: Unsafe use of for..in loop results in incorrectly parsed values in some JavaScript VMs.
This commit is contained in:
commit
230ef846fa
@ -78,7 +78,7 @@
|
|||||||
for (j = k = 0; j < regex.length; j++) {
|
for (j = k = 0; j < regex.length; j++) {
|
||||||
matches = regex[j].exec(this.getUA());
|
matches = regex[j].exec(this.getUA());
|
||||||
if (!!matches) {
|
if (!!matches) {
|
||||||
for (p in props) {
|
for (p = 0; p < props.length; p++) {
|
||||||
match = matches[++k];
|
match = matches[++k];
|
||||||
q = props[p];
|
q = props[p];
|
||||||
// check if given property is actually array
|
// check if given property is actually array
|
||||||
|
2
src/ua-parser.min.js
vendored
2
src/ua-parser.min.js
vendored
File diff suppressed because one or more lines are too long
Loading…
x
Reference in New Issue
Block a user