File tree Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Expand file tree Collapse file tree 4 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -61,8 +61,8 @@ module.exports = (Model, options) => {
61
61
62
62
return Promise . map ( Object . keys ( options . properties ) , property => {
63
63
const config = getPropertyConfig ( options . properties [ property ] )
64
- const callback = config . callback
65
64
const action = ctx . isNewInstance ? 'Calculating' : 'Recalculating'
65
+ const { callback } = config
66
66
67
67
if ( ! callback ) {
68
68
debug ( 'Callback not defined for property %s' , property )
Original file line number Diff line number Diff line change
1
+ 'use strict'
2
+
1
3
const deprecate = require ( 'depd' ) ( 'loopback-ds-calculated-mixin' )
2
4
const calculated = require ( './calculated' )
3
5
4
6
module . exports = function mixin ( app ) {
5
- 'use strict'
6
7
app . loopback . modelBuilder . mixins . define = deprecate . function ( app . loopback . modelBuilder . mixins . define ,
7
8
'app.modelBuilder.mixins.define: Use mixinSources instead' )
8
9
app . loopback . modelBuilder . mixins . define ( 'Calculated' , calculated )
Original file line number Diff line number Diff line change 35
35
"conventional-commit-types" : " ^2.1.0" ,
36
36
"coveralls" : " ^2.13.0" ,
37
37
"dirty-chai" : " ^1.2.2" ,
38
- "eslint-config-fullcube" : " ^2.0.0 " ,
38
+ "eslint-config-fullcube" : " ^2.0.2 " ,
39
39
"loopback" : " ^3.6.0" ,
40
40
"mocha" : " latest" ,
41
41
"mocha-sinon" : " latest" ,
Original file line number Diff line number Diff line change 1
1
const utils = require ( 'loopback-datasource-juggler/lib/utils' )
2
2
const loopback = require ( 'loopback' )
3
-
4
3
const chai = require ( 'chai' )
5
- const expect = chai . expect
4
+
5
+ const { expect } = chai
6
6
7
7
chai . use ( require ( 'chai-datetime' ) )
8
8
chai . use ( require ( 'dirty-chai' ) )
You can’t perform that action at this time.
0 commit comments