mirror of
https://github.com/apricote/Listory.git
synced 2026-01-13 13:11:02 +00:00
fix: remove debug logging
This commit is contained in:
parent
aecc82576a
commit
f56218602e
6 changed files with 0 additions and 25 deletions
|
|
@ -73,7 +73,6 @@ export const getRecentListens = async (
|
|||
}
|
||||
|
||||
const listens: Pagination<Listen> = await res.json();
|
||||
console.log("getRecentListens", { listens });
|
||||
return listens;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,6 @@ function useProvideAuth(): AuthContext {
|
|||
useEffect(() => {
|
||||
(async () => {
|
||||
try {
|
||||
console.log("before calling getUsersMe");
|
||||
const currentUser = await getUsersMe();
|
||||
setUser(currentUser);
|
||||
} catch (err) {
|
||||
|
|
|
|||
|
|
@ -61,12 +61,6 @@ export class AuthService {
|
|||
|
||||
const whitelistedIDs = this.userFilter.split(",");
|
||||
|
||||
console.log("whitelisted ids", {
|
||||
whitelistedIDs,
|
||||
uf: this.userFilter,
|
||||
spotifyID,
|
||||
});
|
||||
|
||||
return whitelistedIDs.includes(spotifyID);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -32,8 +32,6 @@ export class MusicLibraryService {
|
|||
artist.name = data.name;
|
||||
artist.spotify = data.spotify;
|
||||
|
||||
console.log("createArtist", { data, artist });
|
||||
|
||||
await this.artistRepository.save(artist);
|
||||
|
||||
return artist;
|
||||
|
|
|
|||
|
|
@ -14,8 +14,6 @@ export class SpotifyApiService {
|
|||
accessToken,
|
||||
lastRefreshTime,
|
||||
}: SpotifyConnection): Promise<PlayHistoryObject[]> {
|
||||
console.log("SpotifyApiService#getRecentlyPlayedTracks");
|
||||
|
||||
const parameters: { limit: number; after?: number } = {
|
||||
limit: 50,
|
||||
};
|
||||
|
|
@ -24,12 +22,6 @@ export class SpotifyApiService {
|
|||
parameters.after = lastRefreshTime.getTime();
|
||||
}
|
||||
|
||||
console.log(
|
||||
"getRecentlyPlayedTracks parameters",
|
||||
parameters,
|
||||
lastRefreshTime
|
||||
);
|
||||
|
||||
const history = await this.httpService
|
||||
.get<PagingObject<PlayHistoryObject>>(`v1/me/player/recently-played`, {
|
||||
headers: { Authorization: `Bearer ${accessToken}` },
|
||||
|
|
@ -44,7 +36,6 @@ export class SpotifyApiService {
|
|||
accessToken: string,
|
||||
spotifyID: string
|
||||
): Promise<ArtistObject> {
|
||||
console.log("SpotifyApiService#getArtist");
|
||||
const artist = await this.httpService
|
||||
.get<ArtistObject>(`v1/artists/${spotifyID}`, {
|
||||
headers: { Authorization: `Bearer ${accessToken}` },
|
||||
|
|
@ -55,21 +46,16 @@ export class SpotifyApiService {
|
|||
}
|
||||
|
||||
async getAlbum(accessToken: string, spotifyID: string): Promise<AlbumObject> {
|
||||
console.log("SpotifyApiService#getAlbum");
|
||||
|
||||
const album = await this.httpService
|
||||
.get<AlbumObject>(`v1/albums/${spotifyID}`, {
|
||||
headers: { Authorization: `Bearer ${accessToken}` },
|
||||
})
|
||||
.toPromise();
|
||||
|
||||
console.log("getAlbum", { data: album.data });
|
||||
return album.data;
|
||||
}
|
||||
|
||||
async getTrack(accessToken: string, spotifyID: string): Promise<TrackObject> {
|
||||
console.log("SpotifyApiService#getTrack");
|
||||
|
||||
const track = await this.httpService
|
||||
.get<TrackObject>(`v1/tracks/${spotifyID}`, {
|
||||
headers: { Authorization: `Bearer ${accessToken}` },
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@ export class SpotifyService {
|
|||
|
||||
@Interval(20 * 1000)
|
||||
async getRecentlyPlayedTracks(): Promise<void> {
|
||||
console.log("SpotifyService#getRecentlyPlayedTracks");
|
||||
const users = await this.usersService.findAll();
|
||||
|
||||
for (const user of users) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue