This should be `if(!!results)`, double equals and null keyword in javascript cause truthy/falsy problems