Space after ```function()```.  Also prefer this form for readability:

```javascript
$timeout(function() {
    resource.poll(data, returnFunction)
}, 8000);
```