diff options
| author | Jules Laplace <julescarbon@gmail.com> | 2020-02-23 17:19:03 +0100 |
|---|---|---|
| committer | Jules Laplace <julescarbon@gmail.com> | 2020-02-23 17:19:03 +0100 |
| commit | d6d463cf1a1d260d4b36a308b97dc0b7ef5f22fd (patch) | |
| tree | f1223a9f04bd8f4175030b167ab4a7f767470c2d /app/client/live | |
| parent | 752ef11cda9aed54793084c05953cbcd1df09c5e (diff) | |
pause or unpause
Diffstat (limited to 'app/client/live')
| -rw-r--r-- | app/client/live/live.reducer.js | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/app/client/live/live.reducer.js b/app/client/live/live.reducer.js index 1d437e0..d6f8dc5 100644 --- a/app/client/live/live.reducer.js +++ b/app/client/live/live.reducer.js @@ -117,9 +117,16 @@ const liveReducer = (state = liveInitialState, action) => { if (b.indexOf('set_opt') === 0) { const terms = b.split(' ') let key = terms[1] - let value = parseFloat(terms[2]) - if (isNaN(value)) { - value = terms[2] + let value = terms[2] + if (value === 'True') { + value = true + } else if (value === 'False') { + value = false + } else { + value = parseFloat(terms[2]) + if (isNaN(value)) { + value = terms[2] + } } a[key] = value } |
