Debounce setItem and sort refreshes.