const localStorageEntries = Object.entries(localStorage);
const sessionStorageEntries = Object.entries(sessionStorage);

console.log("localStorage entries:", JSON.stringify(localStorageEntries));
console.log("sessionStorage entries:", JSON.stringify(sessionStorageEntries));

localStorageEntries.forEach(([key, value]) => {
  localStorage.setItem(key, value);
});

sessionStorageEntries.forEach(([key, value]) => {
  sessionStorage.setItem(key, value);
});
