mirror of
https://github.com/wavelog/wavelog.git
synced 2026-03-22 10:24:14 +00:00
make the cache adapter as config options and use them when calling the cache lib
This commit is contained in:
@@ -15,7 +15,7 @@ class Rate_limit {
|
||||
|
||||
public function __construct() {
|
||||
$this->CI =& get_instance();
|
||||
$this->CI->load->driver('cache', ['adapter' => 'file']);
|
||||
$this->CI->load->driver('cache', ['adapter' => $this->CI->config->item('cache_adapter'), 'backup' => $this->CI->config->item('cache_backup')]);
|
||||
|
||||
// Load rate limit config - if not set or empty, rate limiting is disabled
|
||||
$this->rate_limits = $this->CI->config->item('api_rate_limits');
|
||||
|
||||
Reference in New Issue
Block a user