[OE-3421] Fixed JS error on page load