@@ -69,7 +69,7 @@ trait QueryCacheModule
69
69
* @param string|null $id
70
70
* @return array
71
71
*/
72
- public function getFromQueryCache (string $ method = 'get ' , array $ columns = ['* ' ], string $ id = null )
72
+ public function getFromQueryCache (string $ method = 'get ' , array $ columns = ['* ' ], ? string $ id = null )
73
73
{
74
74
if (is_null ($ this ->columns )) {
75
75
$ this ->columns = $ columns ;
@@ -95,7 +95,7 @@ public function getFromQueryCache(string $method = 'get', array $columns = ['*']
95
95
* @param string|null $id
96
96
* @return \Closure
97
97
*/
98
- public function getQueryCacheCallback (string $ method = 'get ' , $ columns = ['* ' ], string $ id = null )
98
+ public function getQueryCacheCallback (string $ method = 'get ' , $ columns = ['* ' ], ? string $ id = null )
99
99
{
100
100
return function () use ($ method , $ columns ) {
101
101
$ this ->avoidCache = true ;
@@ -112,7 +112,7 @@ public function getQueryCacheCallback(string $method = 'get', $columns = ['*'],
112
112
* @param string|null $appends
113
113
* @return string
114
114
*/
115
- public function getCacheKey (string $ method = 'get ' , string $ id = null , string $ appends = null ): string
115
+ public function getCacheKey (string $ method = 'get ' , ? string $ id = null , ? string $ appends = null ): string
116
116
{
117
117
$ key = $ this ->generateCacheKey ($ method , $ id , $ appends );
118
118
$ prefix = $ this ->getCachePrefix ();
@@ -128,7 +128,7 @@ public function getCacheKey(string $method = 'get', string $id = null, string $a
128
128
* @param string|null $appends
129
129
* @return string
130
130
*/
131
- public function generateCacheKey (string $ method = 'get ' , string $ id = null , string $ appends = null ): string
131
+ public function generateCacheKey (string $ method = 'get ' , ? string $ id = null , ? string $ appends = null ): string
132
132
{
133
133
$ key = $ this ->generatePlainCacheKey ($ method , $ id , $ appends );
134
134
@@ -147,7 +147,7 @@ public function generateCacheKey(string $method = 'get', string $id = null, stri
147
147
* @param string|null $appends
148
148
* @return string
149
149
*/
150
- public function generatePlainCacheKey (string $ method = 'get ' , string $ id = null , string $ appends = null ): string
150
+ public function generatePlainCacheKey (string $ method = 'get ' , ? string $ id = null , ? string $ appends = null ): string
151
151
{
152
152
$ name = $ this ->connection ->getName ();
153
153
0 commit comments