(obj, data)
| 308 | } |
| 309 | |
| 310 | function validateIndata(obj, data) { |
| 311 | var pos, _key, possible; |
| 312 | for (_key in data) { |
| 313 | if (!data.hasOwnProperty(_key)) continue; |
| 314 | if (!obj[_key] && _key != "__t") { |
| 315 | // trying to set a field that does not exist. Throw error. |
| 316 | possible = ""; |
| 317 | for (pos in obj) { |
| 318 | if (pos != "__t") { |
| 319 | possible += " \t " + pos + " \n "; |
| 320 | } |
| 321 | } |
| 322 | throw Error(tmpWrap(obj.__t) + " does not have field " + _key + |
| 323 | " \n Possible options are: \n" + possible + " \n "); |
| 324 | } |
| 325 | } |
| 326 | } |
| 327 | |
| 328 | function createField(field, key, data, options) { |
| 329 | if (hasFlag(field.flags, "transient") && options.remove_transient){ |
no test coverage detected