mirror of
https://github.com/navidrome/navidrome.git
synced 2026-10-10 11:27:11 +02:00
* [bugfix] player: use userId, other fixes This PR primarily resolves #1928 by switching the foreign key of `player` from `user.user_name` to `user.id`. There are also a few other fixes/changes: - For some bizarre reason, `ip_address` is never returned from `read`/`get`. Change the field to `ip`, which works. Somehow - Update `players_test.go` mock to also check for user agent, replicating the actual code - Update `player_repository.go` `isPermitted` to check user id. I don't know how this worked before... - tests! - a few places referred to `typ`, when it is really `userAgent`. Change the field names * baseRequest -> selectPlayer * remove comment * update migration, make all of persistence foreign key enabled * maybe don't forget to save the file first |
||
|---|---|---|
| .. | ||
| criteria | ||
| request | ||
| album.go | ||
| album_test.go | ||
| annotation.go | ||
| artist.go | ||
| artist_info.go | ||
| artwork_id.go | ||
| artwork_id_test.go | ||
| bookmark.go | ||
| datastore.go | ||
| errors.go | ||
| file_types.go | ||
| file_types_test.go | ||
| genre.go | ||
| get_entity.go | ||
| library.go | ||
| lyrics.go | ||
| lyrics_test.go | ||
| mediafile.go | ||
| mediafile_internal_test.go | ||
| mediafile_test.go | ||
| model_suite_test.go | ||
| player.go | ||
| playlist.go | ||
| playlists_test.go | ||
| playqueue.go | ||
| properties.go | ||
| radio.go | ||
| scrobble_buffer.go | ||
| share.go | ||
| transcoding.go | ||
| user.go | ||
| user_props.go | ||