From 7a91833d22bffdc223f4b88b8b86746bde75add1 Mon Sep 17 00:00:00 2001 From: Shish Date: Sun, 11 Feb 2024 18:36:46 +0000 Subject: [PATCH] [core] show known properties when one is missing --- core/imageboard/image.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/imageboard/image.php b/core/imageboard/image.php index 54bc7b28..79d9c75d 100644 --- a/core/imageboard/image.php +++ b/core/imageboard/image.php @@ -131,7 +131,8 @@ class Image implements \ArrayAccess { assert(is_string($offset)); if(!$this->offsetExists($offset)) { - throw new \OutOfBoundsException("Undefined dynamic property: $offset"); + $known = implode(", ", array_keys(static::$prop_types)); + throw new \OutOfBoundsException("Undefined dynamic property: $offset (Known: $known)"); } return $this->dynamic_props[$offset] ?? null; }