this should be the first line of the function, as a positive check. 
```
if  (err) { ... }
if (result[0]) { ... }
var result = results[0]
// rest of code