mirror of
https://gitlab.com/ultrasonic/ultrasonic.git
synced 2025-06-12 21:42:48 +03:00
Add two ToDos
This commit is contained in:
parent
be356d9c0a
commit
4eeff191aa
@ -141,6 +141,7 @@ class SubsonicAPIClient(
|
|||||||
api.getAvatar(username).execute()
|
api.getAvatar(username).execute()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO: Move this to response checker
|
||||||
private inline fun handleStreamResponse(apiCall: () -> Response<ResponseBody>): StreamResponse {
|
private inline fun handleStreamResponse(apiCall: () -> Response<ResponseBody>): StreamResponse {
|
||||||
val response = apiCall()
|
val response = apiCall()
|
||||||
return if (response.isSuccessful) {
|
return if (response.isSuccessful) {
|
||||||
|
@ -736,6 +736,7 @@ open class RESTMusicService(
|
|||||||
private const val INDEXES_STORAGE_NAME = "indexes"
|
private const val INDEXES_STORAGE_NAME = "indexes"
|
||||||
private const val ARTISTS_STORAGE_NAME = "artists"
|
private const val ARTISTS_STORAGE_NAME = "artists"
|
||||||
|
|
||||||
|
// TODO: Move to response checker
|
||||||
@Throws(SubsonicRESTException::class, IOException::class)
|
@Throws(SubsonicRESTException::class, IOException::class)
|
||||||
fun checkStreamResponseError(response: StreamResponse) {
|
fun checkStreamResponseError(response: StreamResponse) {
|
||||||
if (response.hasError() || response.stream == null) {
|
if (response.hasError() || response.stream == null) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user