3
0

Remove redundant console log, error and debugger

This commit is contained in:
Katrin Yordanova
2022-12-05 11:31:57 +02:00
parent 46cb048be2
commit ee24191c70
10 changed files with 0 additions and 22 deletions

View File

@@ -36,8 +36,6 @@ export default {
const { prefix, title } = opt
return (err = {}) => {
/* eslint-disable no-console */
console.error(err)
const msg = err.message ? (prefix + ': ' + err.message) : prefix
this.toastDanger(msg, title)
}

View File

@@ -2,7 +2,6 @@
import { compose } from '@cortezaproject/corteza-js'
import * as fieldTypes from './loader'
console.error({ ...fieldTypes })
const props = {
namespace: new compose.Namespace(),
module: new compose.Module(),

View File

@@ -3,7 +3,6 @@ import { default as component } from './Bool.vue'
import { compose } from '@cortezaproject/corteza-js'
import * as fieldTypes from './loader'
console.log(fieldTypes)
// const namespace = ({
// canCreateChart: true,
// canCreateModule: true,

View File

@@ -94,11 +94,9 @@ export default {
name: e.name,
slug: e.slug,
})
console.log({ out })
this.$emit('imported', out)
} catch (err) {
console.error(err)
this.$emit('failed', err)
}

View File

@@ -138,8 +138,6 @@ export default {
this.errors = new validator.Validated()
this.errors.push(...details)
console.debug(this.errors)
throw new Error(this.$t('notification:record.validationErrors'))
}
@@ -196,8 +194,6 @@ export default {
if (!!details && Array.isArray(details) && details.length > 0) {
this.errors.push(...details)
console.debug(this.errors)
throw new Error(this.$t('notification:record.validationErrors'))
}
@@ -305,7 +301,6 @@ export default {
await this.dispatchUiEvent('onFormSubmitError')
vRunner()
if (!this.errors.valid()) {
console.debug(this.errors)
throw new Error(this.$t('notification:record.validationErrors'))
}
},
@@ -325,7 +320,6 @@ export default {
this.errors = this.validator.run(this.record)
if (!this.errors.valid()) {
console.debug(this.errors)
throw new Error(this.$t('notification:record.validationErrors'))
}
},

View File

@@ -40,8 +40,6 @@ export default {
if (err.message && err.message.startsWith('notification')) {
err.message = this.$t(`notification:${err.message.substring('notification.'.length)}`)
}
/* eslint-disable no-console */
console.error(err)
// all other messages should be shown as they are
const msg = err.message ? `${prefix}: ${err.message}` : prefix
this.toastDanger(msg, title)

View File

@@ -36,8 +36,6 @@ export default {
const { prefix, title } = opt
return (err = {}) => {
/* eslint-disable no-console */
console.error(err)
const msg = err.message ? (prefix + ': ' + this.$t(err.message)) : prefix
this.toastDanger(msg, title)
}

View File

@@ -40,8 +40,6 @@ export default {
if (err.message && err.message.startsWith('notification')) {
err.message = this.$t(`notification:${err.message.substring('notification.'.length)}`)
}
/* eslint-disable no-console */
console.error(err)
// all other messages should be shown as they are
const msg = err.message ? `${prefix}: ${err.message}` : prefix
this.toastDanger(msg, title)

View File

@@ -36,8 +36,6 @@ export default {
const { prefix, title } = opt
return (err = {}) => {
/* eslint-disable no-console */
console.error(err)
const msg = err.message ? (prefix + ': ' + this.$t(err.message)) : prefix
this.toastDanger(msg, title)
}

View File

@@ -28,8 +28,6 @@ export default {
const { prefix, title } = opt
return (err = {}) => {
/* eslint-disable no-console */
console.error(err)
const msg = err.message ? (prefix + ': ' + err.message) : prefix
this.toastDanger(msg, title)
}