From 763c713f4cd70c0ad339b81c3ea6c4de78d4ae98 Mon Sep 17 00:00:00 2001 From: Ryan Cramer Date: Mon, 11 Dec 2017 05:42:48 -0500 Subject: [PATCH] wireCount updates per processwire/processwire-issues#408 --- wire/modules/Inputfield/InputfieldForm.module | 2 +- wire/modules/Inputfield/InputfieldMarkup.module | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wire/modules/Inputfield/InputfieldForm.module b/wire/modules/Inputfield/InputfieldForm.module index b3ce5a37..16274a7d 100644 --- a/wire/modules/Inputfield/InputfieldForm.module +++ b/wire/modules/Inputfield/InputfieldForm.module @@ -404,7 +404,7 @@ class InputfieldForm extends InputfieldWrapper { $matches = false; if($subfield == 'count') { - $value = count($value); + $value = wireCount($value); if(self::debug) $this->debugNote("Actual count ($debugNote): $value"); } if(is_object($value)) $value = "$value"; diff --git a/wire/modules/Inputfield/InputfieldMarkup.module b/wire/modules/Inputfield/InputfieldMarkup.module index 44e30aba..51b7b972 100644 --- a/wire/modules/Inputfield/InputfieldMarkup.module +++ b/wire/modules/Inputfield/InputfieldMarkup.module @@ -61,7 +61,7 @@ class InputfieldMarkup extends InputfieldWrapper { } $out = trim($out); - if(count($textformatters)) { + if(wireCount($textformatters)) { foreach($textformatters as $className) { $t = $this->wire('modules')->get($className); if(!$t) continue;