From a890dc211439bf2b12c6f1ba9b75818f1cba73b7 Mon Sep 17 00:00:00 2001 From: Toby Zerner Date: Tue, 16 Jun 2015 17:21:04 +0930 Subject: [PATCH] Static relationship collections need to be initialised on subclasses MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Will probably make this whole “custom relationships” thing a trait instead of being on the base class --- .../core/src/Api/Serializers/DiscussionBasicSerializer.php | 2 ++ framework/core/src/Api/Serializers/PostBasicSerializer.php | 2 ++ 2 files changed, 4 insertions(+) diff --git a/framework/core/src/Api/Serializers/DiscussionBasicSerializer.php b/framework/core/src/Api/Serializers/DiscussionBasicSerializer.php index b1c09ed4b..d9f69eedd 100644 --- a/framework/core/src/Api/Serializers/DiscussionBasicSerializer.php +++ b/framework/core/src/Api/Serializers/DiscussionBasicSerializer.php @@ -2,6 +2,8 @@ class DiscussionBasicSerializer extends BaseSerializer { + protected static $relationships = []; + /** * The resource type. * diff --git a/framework/core/src/Api/Serializers/PostBasicSerializer.php b/framework/core/src/Api/Serializers/PostBasicSerializer.php index 25aa96518..f8cfaae0b 100644 --- a/framework/core/src/Api/Serializers/PostBasicSerializer.php +++ b/framework/core/src/Api/Serializers/PostBasicSerializer.php @@ -2,6 +2,8 @@ class PostBasicSerializer extends BaseSerializer { + protected static $relationships = []; + /** * The resource type. *