summaryrefslogtreecommitdiff
path: root/lib/default.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@status.net>2010-12-06 17:05:32 -0500
committerEvan Prodromou <evan@status.net>2010-12-06 17:05:32 -0500
commitb3d47ed6cc3245ddf2f54343b4783fde05708c00 (patch)
tree8f3906f70ba42ab163164cc7f3caf3da8608bbc4 /lib/default.php
parentda8b268e06f4a6217c2bbb4918888001f8e7e4cd (diff)
Make code-dependent cache entries more volatile
If a cache entry is dependent on the code that's running, upgrading (or enabling/disabling plugins) can generate hard-to-track inconsistencies. This change adds a close-to-unique fingerprint of the running code to some cache keys, so that if the fingerprint changes, the old values are ignored and new values are used. If the automated uniqueness fails, an administrator can add an extra config value, $config['site']['build'], that's thrown into the key also.
Diffstat (limited to 'lib/default.php')
-rw-r--r--lib/default.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/default.php b/lib/default.php
index a91fa338f..7388046d3 100644
--- a/lib/default.php
+++ b/lib/default.php
@@ -59,7 +59,8 @@ $default =
'textlimit' => 140,
'indent' => true,
'use_x_sendfile' => false,
- 'notice' => null // site wide notice text
+ 'notice' => null, // site wide notice text
+ 'build' => 1, // build number, for code-dependent cache
),
'db' =>
array('database' => 'YOU HAVE TO SET THIS IN config.php',