Cannot remove localStorage or sessionStorage

Hi all.
I’m using localStorage to save username when user login. But why i cant remove or delete it?
i try to use $localStorage.$reset(); or window.localStorage.removeItem("display_name"); and window.localStorage.clear();

but the username still shown in my console on Chrome.
Is somebody could help me?
Thank you

I would suggest using this it allows you to cache into localStorage and manages all your cache keys.

How are you initially setting the item?