Object.getPrototypeOf fails in Chrome when given a primitive
This commit is contained in:
parent
39de236459
commit
952134a4ac
@ -58,7 +58,7 @@ window.extractFromStock = function() {
|
|||||||
|
|
||||||
|
|
||||||
// finding the required method names for the botguard interface code
|
// finding the required method names for the botguard interface code
|
||||||
if(topObject && Object.getPrototypeOf(topObject) == requestPrototype) {
|
if(topObject && typeof topObject == "object" && Object.getPrototypeOf(topObject) == requestPrototype) {
|
||||||
var methodKey = Object
|
var methodKey = Object
|
||||||
.keys(topObject)
|
.keys(topObject)
|
||||||
.filter(function(key) { return typeof key == "string"; })[0];
|
.filter(function(key) { return typeof key == "string"; })[0];
|
||||||
|
Loading…
x
Reference in New Issue
Block a user