1
0
mirror of https://github.com/processwire/processwire.git synced 2025-08-16 11:44:42 +02:00

Various minor updates

This commit is contained in:
Ryan Cramer
2019-06-07 12:08:55 -04:00
parent a88c6a49c7
commit f6c210f686
7 changed files with 75 additions and 52 deletions

View File

@@ -708,6 +708,7 @@ class InputfieldWrapper extends Inputfield implements \Countable, \IteratorAggre
*
*/
public function ___renderValue() {
if(!count($this->children)) return '';
$this->addClass('InputfieldRenderValueMode');
$this->set('renderValueMode', true);
$out = $this->render();
@@ -806,7 +807,7 @@ class InputfieldWrapper extends Inputfield implements \Countable, \IteratorAggre
$inputfield->resetTrackChanges();
}
if(is_null($out)) return '';
if(!strlen($out)) $out = ' '; // prevent output from being skipped over
if(!strlen($out) && !$inputfield instanceof InputfieldWrapper) $out = ' '; // prevent output from being skipped over
return $out;
}

View File

@@ -310,6 +310,7 @@ class Modules extends WireArray {
*
*/
public function __construct($path) {
parent::__construct();
$this->addPath($path);
$this->coreModulesDir = '/' . $this->wire('config')->urls->data('modules');
}
@@ -2690,9 +2691,8 @@ class Modules extends WireArray {
* - `minify` (bool): Remove non-applicable and properties that match defaults? (default=false, or true when getting `all`)
* - `noCache` (bool): prevents use of cache to retrieve the module info. (default=false)
* @return array Associative array of module information
* @throws WireException when a module exists but has no means of returning module info
* @see Modules::getModuleInfoVerbose()
* @todo move all getModuleInfo methods to their own ModuleInfo class and break this method down further.
* @todo move all getModuleInfo methods to their own ModuleInfo class and break this method down further.
*
*/
public function getModuleInfo($class, array $options = array()) {
@@ -3014,7 +3014,6 @@ class Modules extends WireArray {
* - `noCache` (bool): prevents use of cache to retrieve the module info
* - `noInclude` (bool): prevents include() of the module file, applicable only if it hasn't already been included
* @return array Associative array of module information
* @throws WireException when a module exists but has no means of returning module info
* @see Modules::getModuleInfo()
*
*/