Fix localStorage issue