We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents bf51188 + fac1ce6 commit 39e34f7Copy full SHA for 39e34f7
src/Repository/DynamoDBRepository.php
@@ -291,7 +291,15 @@ public function getOneById(
291
);
292
}
293
294
- return $this->hydrator->hydrate($this->marshaler->unmarshalItem($output[0]));
+ $result = $this->hydrator->hydrate($this->marshaler->unmarshalItem($output[0]));
295
+
296
+ if ((is_object($result)) && (method_exists($result, 'hasExpired')) && ($result->hasExpired())) {
297
+ throw new EntityNotFoundException(
298
+ sprintf('%s by ID %s has expired', $this->modelClassName, $id)
299
+ );
300
+ }
301
302
+ return $result;
303
304
305
/**
0 commit comments