Do not set unit value or description on variant when unpacked field is undefined

This commit is contained in:
Rohan Mitchell
2013-12-12 10:50:03 +11:00
parent 42d3947861
commit a67c7b808d
2 changed files with 10 additions and 4 deletions

View File

@@ -552,6 +552,11 @@ describe "AdminBulkProductsCtrl", ->
unit_description: ''
unit_value_with_description: ""
it "sets nothing when the field is undefined", ->
testVariant = {}
scope.packVariant(testVariant)
expect(testVariant).toEqual {}
describe "filtering products", ->
beforeEach ->