Skip to content

Commit

Permalink
Update doc block.
Browse files Browse the repository at this point in the history
In PHP5.4 there is no reason to make a closure around $this.
  • Loading branch information
markstory committed Dec 26, 2013
1 parent 4a44ad4 commit 3792f56
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions Cake/Cache/Cache.php
Expand Up @@ -399,12 +399,11 @@ public static function enabled() {
*
* Examples:
*
* Using a Closure to provide data, assume $this is a Model:
* Using a Closure to provide data, assume `$this` is a Table object:
*
* {{{
* $model = $this;
* $results = Cache::remember('all_articles', function() use ($model) {
* return $model->find('all');
* $results = Cache::remember('all_articles', function() {
* return $this->find('all');
* });
* }}}
*
Expand Down

0 comments on commit 3792f56

Please sign in to comment.