I am developing a website and noticed that the 'remember me' login functionality was not working.

So I added a remember me section to the security.yml

```
firewalls:
    secured_area:
        pattern:    ^/
        form_login:
            check_path: /login_check
            login_path: /login
            provider: fos_userbundle
        remember_me:
            key:      "%secret%"
            lifetime: 31536000
            path:     /
            domain:   ~
        logout:
            path:   /logout
            target: /
        anonymous: ~

```

For reference here is the access control section:

```
access_control:
    - { path: ^/login$, role: IS_AUTHENTICATED_ANONYMOUSLY }
    - { path: ^/register, role: IS_AUTHENTICATED_ANONYMOUSLY }
    - { path: ^/resetting, role: IS_AUTHENTICATED_ANONYMOUSLY }
    - { path: ^/admin/, role: ROLE_ADMIN }
    - { path: ^/account, roles: ROLE_USER }

```

The remember me functionality now seems to work because if I log in then close the browser and reload the browser I am still logged into the site. However if I try and go to any page that requires a user to be logged in (such as /account/settings) I get the following error:

```
The controller must return a response (false given).
500 Internal Server Error - LogicException

```

I have cleared the cache and that does not solve the problem.

Any ideas on how to fix this?