only add semi-colon if js and no final semi-colon
ensure new code is covered and fixes issue