結果 : javascript string remove after last occurrence of character