mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-21 14:50:08 +03:00
M #~: Minor fix to helper function (#2111)
This commit is contained in:
parent
c817b6fd62
commit
60c033b563
@ -79,7 +79,7 @@ export const booleanToString = (bool) => (bool ? T.Yes : T.No)
|
||||
* in other cases, return false.
|
||||
*/
|
||||
export const stringToBoolean = (str) =>
|
||||
String(str).toLowerCase() === 'yes' || +str === 1
|
||||
['yes', 'true'].includes(String(str).toLowerCase()) || +str === 1
|
||||
|
||||
/**
|
||||
* Formats a number into a string according to the currency configuration.
|
||||
|
Loading…
x
Reference in New Issue
Block a user