JSON token count now depends on max product count
Improved debounce code