mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-09 18:44:16 +00:00
added toBoolean
string prototype
This commit is contained in:
parent
a7abc3df22
commit
b8a4916f8a
@ -19,6 +19,10 @@ String.prototype.toTitleCase = function () {
|
||||
})
|
||||
}
|
||||
|
||||
String.prototype.toBoolean = function () {
|
||||
return this === "true"
|
||||
}
|
||||
|
||||
Promise.tasked = function (promises) {
|
||||
return new Promise(async (resolve, reject) => {
|
||||
let rejected = false
|
||||
@ -76,6 +80,8 @@ class App extends React.Component {
|
||||
static async initialize() {
|
||||
window.app.version = config.package.version
|
||||
|
||||
window.app.message = antd.message
|
||||
|
||||
// check if electron library is available
|
||||
if (typeof window.electron !== "undefined") {
|
||||
window.isElectron = true
|
||||
|
Loading…
x
Reference in New Issue
Block a user