localStorage of an array and json obj