Skip to content

Commit 308c18b

Browse files
committed
Fix total calculation in example
1 parent 61c0c85 commit 308c18b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

example/client-server/models.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,5 +35,5 @@ CartItem.remoteMethod('sum',
3535
);
3636

3737
CartItem.prototype.total = function() {
38-
return this.price * this.qty * 1 + this.tax;
38+
return this.price * this.qty * (1 + this.tax);
3939
};

0 commit comments

Comments
 (0)