🏡 index : ~doyle/koselig.git

author Jordan Doyle <jordan@doyle.wf> 2016-11-27 19:22:11.0 +00:00:00
committer Jordan Doyle <jordan@doyle.wf> 2016-11-27 19:22:11.0 +00:00:00
commit
433da14359cbde3a8e43f528b723d38b245d8d36 [patch]
tree
934e3c8541ce192f451942520d616dc4826b0cb5
parent
056ff0ecc3498f91ba6160c7f19b79a979512219
parent
7186deceba3ccc4995284120cff4cb7498c05b96
download
433da14359cbde3a8e43f528b723d38b245d8d36.tar.gz

Merge branch 'master' of https://github.com/koselig/library



Diff

 src/Models/Comment.php | 2 +-
 src/Models/Post.php    | 1 +
 2 files changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/Models/Comment.php b/src/Models/Comment.php
index 42606d1..3fd5210 100644
--- a/src/Models/Comment.php
+++ b/src/Models/Comment.php
@@ -81,7 +81,7 @@ class Comment extends Model
     */
    public function children()
    {
        return $this->hasMany(Comment::class, 'comment_parent');
        return $this->hasMany(self::class, 'comment_parent');
    }

    /**
diff --git a/src/Models/Post.php b/src/Models/Post.php
index 230fb30..9fa880f 100644
--- a/src/Models/Post.php
+++ b/src/Models/Post.php
@@ -86,6 +86,7 @@ class Post extends Model
     * Get all the comments that belong to this post.
     *
     * @param bool $topLevel only get the top level comments for this post
     *
     * @return HasMany
     */
    public function comments(bool $topLevel = true)