I\'m using FOSuserbundle to get started with User registration https://github.com/FriendsOfSymfony/FOSUserBundle
I\'ve got it registering / logging in and out. What
{{ app.user.username|default('') }}
Just present login username for example, filter function default('') should be nice when user is NOT login by just avoid annoying error message.