R1:c1d86da5b209
R1:c1d86da5b209
Initialize $cache_key variable in CelerityResourceController.php
Summary:
`$cache_key` is unconditionally called in `$cache->setKey($cache_key, $data)` but is only defined if the previous condition `if ($is_cacheable && $is_locally_cacheable && !$dev_mode)` was true.
Thus initialize the variable to avoid a theoretical exception. (No additional null check is needed as `$cache` gets defined in the same condition.)
Test Plan: Carefully read the code.
Reviewers: O1 Blessed Committers, valerio.bozzolan…
Summary:
`$cache_key` is unconditionally called in `$cache->setKey($cache_key, $data)` but is only defined if the previous condition `if ($is_cacheable && $is_locally_cacheable && !$dev_mode)` was true.
Thus initialize the variable to avoid a theoretical exception. (No additional null check is needed as `$cache` gets defined in the same condition.)
Test Plan: Carefully read the code.
Reviewers: O1 Blessed Committers, valerio.bozzolan…
Repository: R1 hydra
Commit Date: Jun 11 2024