PluginProbe
Polylang / 2.8
Polylang v2.8
3.8.9 3.8.8 3.8.7 3.8.6 3.8.5 3.8.4 3.8.3 2.7 2.7.0.1 2.7.1 2.7.2 2.7.3 2.7.4 2.8 2.8.1 2.8.2 2.8.3 2.8.4 2.9 2.9.1 2.9.2 3.0 3.0.1 3.0.2 3.0.3 All 233 releases
← All changes | include/cache.php +1 -16 3.02.8 View file →
@@ -9,23 +9,11 @@
9 9 *
10 10 * @since 1.7
11 11 */
12 12 class PLL_Cache {
13 - /**
14 - * Current site id.
15 - *
16 - * @var int
17 - */
18 - protected $blog_id;
13 + protected $blog_id, $cache;
19 14
20 15 /**
21 - * The cache container.
22 - *
23 - * @var array
24 - */
25 - protected $cache;
26 -
27 - /**
28 16 * Constructor
29 17 *
30 18 * @since 1.7
31 19 */
@@ -39,9 +27,8 @@
39 27 *
40 28 * @since 1.7
41 29 *
42 30 * @param int $new_blog
43 - * @return void
44 31 */
45 32 public function switch_blog( $new_blog ) {
46 33 $this->blog_id = $new_blog;
47 34 }
@@ -52,9 +39,8 @@
52 39 * @since 1.7
53 40 *
54 41 * @param string $key
55 42 * @param mixed $data
56 - * @return void
57 43 */
58 44 public function set( $key, $data ) {
59 45 $this->cache[ $this->blog_id ][ $key ] = $data;
60 46 }
@@ -76,9 +62,8 @@
76 62 *
77 63 * @since 1.7
78 64 *
79 65 * @param string $key
80 - * @return void
81 66 */
82 67 public function clean( $key = '' ) {
83 68 if ( empty( $key ) ) {
84 69 unset( $this->cache[ $this->blog_id ] );