Fixes: #1930 now using javascript