Skip to content

Commit

Permalink
chore: add DrupalPractice as a phpcs standard (#31)
Browse files Browse the repository at this point in the history
  • Loading branch information
rishtigupta authored Mar 19, 2024
1 parent 1100add commit 7bd13f2
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/on-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ jobs:
- name: Run PHPCS
working-directory: ${{ env.DRUPAL_ROOT }}
run: |
vendor/bin/phpcs $MODULE_FOLDER --standard=Drupal \
vendor/bin/phpcs $MODULE_FOLDER --standard=Drupal,DrupalPractice \
--extensions=php,module,inc,install,test,info
- name: Start Drush webserver and chromedriver
Expand Down
9 changes: 8 additions & 1 deletion src/MomentoCacheBackend.php
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,14 @@ public function getMultiple(&$cids, $allow_invalid = FALSE) {
foreach ($futures as $cid => $future) {
$getResponse = $future->wait();
if ($getResponse->asHit()) {
$result = unserialize($getResponse->asHit()->valueString());
$result = unserialize(
$getResponse->asHit()->valueString(),
[
'allowed_classes' => [
\stdClass::class,
],
]
);

if ($result->created <= $this->lastBinDeletionTime) {
continue;
Expand Down

0 comments on commit 7bd13f2

Please sign in to comment.