Skip to content

Commit

Permalink
Add Method Comments
Browse files Browse the repository at this point in the history
added comments for methods: element, getElementFileName for
functionality to allow using elements of the application from inside
plugin
  • Loading branch information
hashmode authored and markstory committed Sep 16, 2016
1 parent 5ad7d95 commit c59d9c3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/View/View.php
Expand Up @@ -475,6 +475,8 @@ public function layout($name = null)
* - `callbacks` - Set to true to fire beforeRender and afterRender helper callbacks for this element.
* Defaults to false.
* - `ignoreMissing` - Used to allow missing elements. Set to true to not throw exceptions.
* - `plugin` - setting to false will force to use the application's element from plugin templates, when the
* plugin has element with same name. Defaults to true
* @return string Rendered Element
* @throws \Cake\View\Exception\MissingElementException When an element is missing and `ignoreMissing`
* is false.
Expand Down Expand Up @@ -1147,7 +1149,6 @@ public function pluginSplit($name, $fallback = true)
$name = $second;
$plugin = $first;
}

if (isset($this->plugin) && !$plugin && $fallback) {
$plugin = $this->plugin;
}
Expand Down Expand Up @@ -1193,6 +1194,7 @@ protected function _getLayoutFileName($name = null)
* Finds an element filename, returns false on failure.
*
* @param string $name The name of the element to find.
* @param bool $pluginCheck - if false will ignore the request's plugin if parsed plugin is not loaded
* @return string|false Either a string to the element filename or false when one can't be found.
*/
protected function _getElementFileName($name, $pluginCheck = true)
Expand Down

0 comments on commit c59d9c3

Please sign in to comment.