Performance optimization

Switch checking `Object.prototype.toString` with `instanceof`.

http://jsperf.com/tostring-vs-instance2of

`instanceof` works much faster so if it's equals true second condition will be not executed.