AmpersandJS/ampersand-state — pull request #118 by latentflip (2014-12-09 14:52:35+00:00)
Title: Don’t fallback to a datatype default value if setOnce is true. [semi-urgent]

This fixes an issue caused by #114 and raised in the comments there.

Currently a field definition like:

```js
props: {
foo: {
type: 'string',
setOnce: true,
required: true
}
}
```

creates a property that can never be set, as the default gets pulled off the datatype and set as the field default, and it can never be set to a "real" value without raising an exception.

I've changed the behaviour such that if setOnce is true, then the dataType default will never be used as a fallback value for the default, which I think makes sense, as setOnce with a default value is pretty weird anyway, especially if the default is `""` or something that came from the dataType.