我用的环境
PHP 版本:7.1
overtrue/wechat 版本:4.1.16
是否使用了框架?框架名称:larvarl 5.5.44
第一次获取accessToken缓存throw exception
$ok = $this->getCache()->set($this->getCacheKey(), [
$this->tokenKey => $token,
'expires_in' => $lifetime,
], $lifetime - $this->safeSeconds);
if (!$ok) {
throw new RuntimeException('Failed to cache access token.');
}
关于此段代码,查阅larval 源码发现 如果使用larval 自己的缓存 此处是没有返回值得即ok永远是null
然后就抛出异常了,请查阅谢谢。
