Refactor ajax dream controller

Simply use
```php
return $result;
```
in this method