timob-14324: fix preferences crashes on first launch
Merge pull request #4436 from hieupham007/timob-14324

timob-14324: fix preferences crashes on first launch