Exemplo n.º 1
0
        public async Task <IActionResult> GetLibrarySongs(string debugCacheKey = "1")
        {
            async Task <SpotifyItemResponse <SongItem> > GetSongs() => await _spotifyClient.GetAllLibrarySongs(AccessToken);

#if DEBUG
            var librarySongs = await GetWithDebugCaching(GetSongs, nameof(GetLibrarySongs), debugCacheKey);
#else
            var librarySongs = await GetSongs();
#endif
            return(new OkObjectResult(librarySongs));
        }