Fixes #162. This PR fixes an unclear function comment and adds a clean error exit to the failure to find a config file. I believe this is better for a user that hasn't made their config file yet or passing the wrong path parameter compared to just panicking.
Example run with missing main.json
> .\jellyfin-rpc.exe
2024-10-24 13:58:46 INFO [jellyfin_rpc] Initializing Jellyfin-RPC
2024-10-24 13:58:47 ERROR [jellyfin_rpc] Config file could not be found at path: C:\Users\tronl\AppData\Roaming\jellyfin-rpc\main.json
2024-10-24 13:58:47 ERROR [jellyfin_rpc] Please create a proper config file: https://github.com/Radiicall/jellyfin-rpc/wiki/Setup
Example run with incorrect config parameter
> .\jellyfin-rpc.exe -c ./config.json
2024-10-24 14:03:21 INFO [jellyfin_rpc] Initializing Jellyfin-RPC
2024-10-24 14:03:21 ERROR [jellyfin_rpc] Config file could not be found at path: ./config.json
2024-10-24 14:03:21 ERROR [jellyfin_rpc] Please create a proper config file: https://github.com/Radiicall/jellyfin-rpc/wiki/Setup
Fixes #162. This PR fixes an unclear function comment and adds a clean error exit to the failure to find a config file. I believe this is better for a user that hasn't made their config file yet or passing the wrong path parameter compared to just panicking.
Example run with missing main.json
Example run with incorrect config parameter