aboutsummaryrefslogtreecommitdiff
path: root/Database/DetailsHelper.cs
blob: 4053594d50e97aab877410674c55a1345687f5ce (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using System.Collections.Generic;
using Newtonsoft.Json;

namespace Database {
    public static class DetailsHelper {
        public static async Task<Dictionary<string, string>> GetDetails() {
            string json = string.Join('\n', await File.ReadAllLinesAsync("details.json"));
            return JsonConvert.DeserializeObject<Dictionary<string, string>>(json);
        }
    }
}