summaryrefslogtreecommitdiffstats
path: root/DOCS
diff options
context:
space:
mode:
authorAvi Halachmi (:avih) <avihpit@yahoo.com>2021-10-31 01:08:08 +0300
committersfan5 <sfan5@live.de>2021-11-01 14:31:18 +0100
commitf6b834a2fcd9a00ca6ed150aede436b42a3107e7 (patch)
treeac3fae5f2df40669a79d0a67b313730d2f03124f /DOCS
parent3ea1f8e80a33edff8d944ea2e82b0dfe4ff25215 (diff)
downloadmpv-f6b834a2fcd9a00ca6ed150aede436b42a3107e7.tar.bz2
mpv-f6b834a2fcd9a00ca6ed150aede436b42a3107e7.tar.xz
js: ~~/init.js: use mp.find_config_file
The problem with the previous code - which used mp.get_user_path, is that it returns a path even with --no-config, and even if the file doesn't exist. This is why we tested the "config" property, and also used mp.utils.file_info to check that the file exists. mp.find_config_file doesn't return a path with no-cofig and doesn't return a path if the file doesn't exists. It's simpler and better.
Diffstat (limited to 'DOCS')
0 files changed, 0 insertions, 0 deletions