r43647 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r43646‎ | r43647 | r43648 >
Date:22:16, 17 November 2008
Author:yaron
Status:deferred
Tags:
Comment:
Added 'dummy FormTemplateField' to be returned when strict parsing doesn't
find a field
Modified paths:
  • /trunk/extensions/SemanticForms/includes/SF_FormClasses.inc (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/includes/SF_FormClasses.inc
@@ -265,8 +265,13 @@
266266 }
267267 }
268268 if ($the_field == null) {
269 - if ($strict_parsing)
270 - return null;
 269+ if ($strict_parsing) {
 270+ $dummy_ftf = new SFFormTemplateField();
 271+ $dummy_ftf->template_field = new SFTemplateField();
 272+ $dummy_ftf->is_list = false;
 273+ $dummy_ftf->field_args = array();
 274+ return $dummy_ftf;
 275+ }
271276 $the_field = new SFTemplateField();
272277 }
273278

Status & tagging log