Fixed small JS bug