From 17e92f885bb7ae863ad54180d29ab5d73dbcef09 Mon Sep 17 00:00:00 2001 From: xiaomlove Date: Sun, 16 May 2021 00:35:48 +0800 Subject: [PATCH] define NEXUS_START in api --- app/Models/User.php | 8 ++++++++ bootstrap/app.php | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/app/Models/User.php b/app/Models/User.php index 3176b8a1..efa6dffd 100644 --- a/app/Models/User.php +++ b/app/Models/User.php @@ -176,11 +176,19 @@ class User extends Authenticatable return $this->hasMany(Message::class, 'receiver'); } + /** + * torrent comments + * @return \Illuminate\Database\Eloquent\Relations\HasMany + */ public function comments() { return $this->hasMany(Comment::class, 'user'); } + /** + * forum posts + * @return \Illuminate\Database\Eloquent\Relations\HasMany + */ public function posts() { return $this->hasMany(Post::class, 'userid'); diff --git a/bootstrap/app.php b/bootstrap/app.php index 3db5aec2..59a47a18 100644 --- a/bootstrap/app.php +++ b/bootstrap/app.php @@ -1,7 +1,7 @@