sealcode / sealious

An extensible, declarative node framework
25 stars 2 forks source link

Broken property no_file_value in field type file #230

Closed arkadiusz-wieczorek closed 9 years ago

arkadiusz-wieczorek commented 9 years ago

I can't post new instance of resource to resource type with field type file.

16:15:35.289 - info: Sealious@0.6.10 is up-to-date.
16:15:38.449 - error:     POST /api/v1/testing
            from: 127.0.0.1, mime: multipart/form-data
            result: 
16:15:38.449 - error:  TypeError: Cannot read property 'no_file_value' of undefined
    at Sealious.ChipTypes.FieldType.decode (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/base-chips/field_type.file.js:34:19)
    at tryCatcher (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/util.js:26:23)
    at /home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/method.js:15:34
    at decode (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/field-type.js:138:36)
    at decode_value (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type-field.js:55:20)
    at decode_values (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type.js:194:32)
    at decode_db_entry (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type.js:203:15)
    at /home/arkadiusz/Projects/Sealious-development/Sealious/lib/core-services/resource-manager.js:52:33
    at bound (domain.js:250:14)
    at runBound (domain.js:263:12)
    at tryCatcher (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/util.js:26:23)
    at Promise._settlePromiseFromHandler (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/promise.js:503:31)
    at Promise._settlePromiseAt (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/promise.js:577:18)
    at Async._drainQueue (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:128:12)
    at Async._drainQueues (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:133:10)
    at Immediate.Async.drainQueues [as _onImmediate] (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:15:14)
    at processImmediate [as _immediateCallback] (timers.js:371:17)
TypeError: Cannot read property 'no_file_value' of undefined
    at Sealious.ChipTypes.FieldType.decode (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/base-chips/field_type.file.js:34:19)
    at tryCatcher (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/util.js:26:23)
    at /home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/method.js:15:34
    at decode (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/field-type.js:138:36)
    at decode_value (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type-field.js:55:20)
    at decode_values (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type.js:194:32)
    at decode_db_entry (/home/arkadiusz/Projects/Sealious-development/Sealious/lib/chip-types/resource-type.js:203:15)
    at /home/arkadiusz/Projects/Sealious-development/Sealious/lib/core-services/resource-manager.js:52:33
    at bound (domain.js:250:14)
    at runBound (domain.js:263:12)
    at tryCatcher (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/util.js:26:23)
    at Promise._settlePromiseFromHandler (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/promise.js:503:31)
    at Promise._settlePromiseAt (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/promise.js:577:18)
    at Async._drainQueue (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:128:12)
    at Async._drainQueues (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:133:10)
    at Immediate.Async.drainQueues [as _onImmediate] (/home/arkadiusz/Projects/Sealious-development/Sealious/node_modules/bluebird/js/main/async.js:15:14)
    at processImmediate [as _immediateCallback] (timers.js:371:17)