I had assumed you were using tabs instead of spaces, but that's not the case... these are spaces, there are just too many of them: 

This patch: 
```js
if (typeof value !== 'string') {
     value = value.value;
   }else {
     value = value.trim();
   }
```

Corrected: 
```js
if (typeof value !== 'string') {
  value = value.value;
} else {
  value = value.trim();
}
```