Fix: revert return

This commit is contained in:
LustyRain 2017-10-05 00:09:51 +09:00
parent 0f00d73c70
commit e1e5a292f2
2 changed files with 3 additions and 5 deletions

View file

@ -166,8 +166,7 @@ class CakeEventManager {
*/ */
public function detach($callable, $eventKey = null) { public function detach($callable, $eventKey = null) {
if ($callable instanceof CakeEventListener) { if ($callable instanceof CakeEventListener) {
$this->_detachSubscriber($callable, $eventKey); return $this->_detachSubscriber($callable, $eventKey);
return;
} }
if (empty($eventKey)) { if (empty($eventKey)) {
foreach (array_keys($this->_listeners) as $eventKey) { foreach (array_keys($this->_listeners) as $eventKey) {

View file

@ -581,11 +581,10 @@ class File {
*/ */
public function clearStatCache($all = false) { public function clearStatCache($all = false) {
if ($all === false && version_compare(PHP_VERSION, '5.3.0') >= 0) { if ($all === false && version_compare(PHP_VERSION, '5.3.0') >= 0) {
clearstatcache(true, $this->path); return clearstatcache(true, $this->path);
return;
} }
clearstatcache(); return clearstatcache();
} }
/** /**