cleanup res.error overly complex

This commit is contained in:
2020-04-09 22:45:05 +00:00
parent baadc9c3c2
commit ae3baeb954
13 changed files with 32 additions and 34 deletions

View File

@@ -145,7 +145,7 @@ export default {
.get(url)
.then(res => {
vm.formState.ready = true;
if (res.error != undefined) {
if (res.error) {
vm.formState.serverError = res.error;
window.$gz.form.setErrorBoxErrors(vm);
} else {
@@ -184,7 +184,7 @@ export default {
.upsert(url, vm.obj)
.then(res => {
vm.formState.loading = false;
if (res.error != undefined) {
if (res.error) {
vm.formState.serverError = res.error;
window.$gz.form.setErrorBoxErrors(vm);
} else {