()
| 194 | } |
| 195 | |
| 196 | validate () { |
| 197 | const errors = this.getValidationErrors() |
| 198 | if (errors != null ? errors.length : undefined) { |
| 199 | if (!(typeof application !== 'undefined' && application !== null ? application.testing : undefined)) { |
| 200 | console.debug(`Validation failed for ${this.constructor.className}: '${this.get('name') || this}'.`) |
| 201 | for (const error of Array.from(errors)) { |
| 202 | console.debug('\t', error.dataPath, ':', error.message) |
| 203 | } |
| 204 | if (typeof console.trace === 'function') { |
| 205 | console.trace('cm err', errors) |
| 206 | } |
| 207 | } |
| 208 | return errors |
| 209 | } |
| 210 | } |
| 211 | |
| 212 | save (attrs, options) { |
| 213 | if (options == null) { options = {} } |
nothing calls this directly
no test coverage detected