| @@ 338-344 (lines=7) @@ | ||
| 335 | // Raw type might be negative when using the fully optimized form |
|
| 336 | // of stdclass, which indicates allow_null == true |
|
| 337 | $rtype = is_int($def) ? $def : $def->type; |
|
| 338 | if ($rtype < 0) { |
|
| 339 | $type = -$rtype; |
|
| 340 | $allow_null = true; |
|
| 341 | } else { |
|
| 342 | $type = $rtype; |
|
| 343 | $allow_null = isset($def->allow_null); |
|
| 344 | } |
|
| 345 | ||
| 346 | try { |
|
| 347 | $value = $this->parser->parse($value, $type, $allow_null); |
|
| @@ 183-189 (lines=7) @@ | ||
| 180 | ||
| 181 | $ret .= $this->start('td'); |
|
| 182 | $def = $this->config->def->info["$ns.$directive"]; |
|
| 183 | if (is_int($def)) { |
|
| 184 | $allow_null = $def < 0; |
|
| 185 | $type = abs($def); |
|
| 186 | } else { |
|
| 187 | $type = $def->type; |
|
| 188 | $allow_null = isset($def->allow_null); |
|
| 189 | } |
|
| 190 | if (!isset($this->fields[$type])) { |
|
| 191 | $type = 0; |
|
| 192 | } // default |
|