Fix default value setting

When we add parameter from hook a we set value nil so default value
would be used but it would also set value_set flag to true. Therefore a
value would be used instead of default value. This fix sets default
value to be the value of such parameter.
Merge pull request #91 from ares/master

Fix default value setting