dopamine icon indicating copy to clipboard operation
dopamine copied to clipboard

searching in japanese

Open EYHN opened this issue 2 years ago • 0 comments

A chance discovery, I am not very familiar with Japanese.

I have a song named グリーンライツ·セレナーデ, when i search with グリーンライツ I got nothing, but with グリーンライツ I got the song. Two strings that look exactly the same but have different byte codes.

By checking the source code, I think it is because we normalized the original text of the song name and not the search text that caused this problem.

https://github.com/digimezzo/dopamine/blob/76720aae321f3b1339755093434d73e531a1fdba/src/app/services/search/search.service.ts#L52-L61

https://github.com/digimezzo/dopamine/blob/76720aae321f3b1339755093434d73e531a1fdba/src/app/common/strings.ts#L49

reproduce:

EYHN avatar Sep 19 '22 03:09 EYHN