Skip to content

Commit

Permalink
fix(android): use “none” instead of “idle” for none state (#1924)
Browse files Browse the repository at this point in the history
  • Loading branch information
puckey authored Feb 21, 2023
1 parent 417f3c4 commit e125045
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ val AudioPlayerState.asLibState: State
AudioPlayerState.BUFFERING -> State.Buffering
AudioPlayerState.PAUSED -> State.Paused
AudioPlayerState.PLAYING -> State.Playing
AudioPlayerState.IDLE -> State.Idle
AudioPlayerState.IDLE -> State.None
AudioPlayerState.ENDED -> State.Ended
AudioPlayerState.ERROR -> State.Error
AudioPlayerState.STOPPED -> State.Stopped
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package com.doublesymmetry.trackplayer.model

enum class State(val state: String) {
Buffering("buffering"),
Idle("idle"),
None("none"),
Ready("ready"),
Paused("paused"),
Stopped("stopped"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ class MusicModule(reactContext: ReactApplicationContext) : ReactContextBaseJavaM
constants["CAPABILITY_JUMP_BACKWARD"] = Capability.JUMP_BACKWARD.ordinal

// States
constants["STATE_NONE"] = State.Idle.state
constants["STATE_NONE"] = State.None.state
constants["STATE_READY"] = State.Ready.state
constants["STATE_PLAYING"] = State.Playing.state
constants["STATE_PAUSED"] = State.Paused.state
Expand Down

0 comments on commit e125045

Please sign in to comment.