fix: chain saves
This commit is contained in:
parent
c4ca91b59b
commit
3311c6c5fb
1 changed files with 4 additions and 6 deletions
|
|
@ -110,18 +110,16 @@ const Notifications = ({
|
||||||
|
|
||||||
const twilioSave = it => {
|
const twilioSave = it => {
|
||||||
setError(null)
|
setError(null)
|
||||||
R.compose(save(null), toNamespace('sms'))({ active: true })
|
saveAccount({
|
||||||
return saveAccount({
|
|
||||||
variables: { accounts: { twilio: it } }
|
variables: { accounts: { twilio: it } }
|
||||||
})
|
}).then(() => R.compose(save(null), toNamespace('sms'))({ active: true }))
|
||||||
}
|
}
|
||||||
|
|
||||||
const mailgunSave = it => {
|
const mailgunSave = it => {
|
||||||
setError(null)
|
setError(null)
|
||||||
R.compose(save(null), toNamespace('email'))({ active: true })
|
saveAccount({
|
||||||
return saveAccount({
|
|
||||||
variables: { accounts: { mailgun: it } }
|
variables: { accounts: { mailgun: it } }
|
||||||
})
|
}).then(() => R.compose(save(null), toNamespace('email'))({ active: true }))
|
||||||
}
|
}
|
||||||
|
|
||||||
const isEditing = key => editingKey === key
|
const isEditing = key => editingKey === key
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue