From 8dc1f41b73c7211b39e1dd8bbeacee01f1700641 Mon Sep 17 00:00:00 2001 From: Dane Everitt Date: Fri, 10 Feb 2017 17:41:56 -0500 Subject: [PATCH] More code cleanup. --- app/Repositories/APIRepository.php | 2 +- app/Services/NotificationService.php | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/app/Repositories/APIRepository.php b/app/Repositories/APIRepository.php index 382e6a274..14348b2db 100644 --- a/app/Repositories/APIRepository.php +++ b/app/Repositories/APIRepository.php @@ -149,7 +149,7 @@ class APIRepository $secretKey = str_random(16) . '.' . str_random(7) . '.' . str_random(7); $key = new Models\APIKey; $key->fill([ - 'user' => $this->user->id, + 'user_id' => $this->user->id, 'public' => str_random(16), 'secret' => Crypt::encrypt($secretKey), 'allowed_ips' => empty($this->allowed) ? null : json_encode($this->allowed), diff --git a/app/Services/NotificationService.php b/app/Services/NotificationService.php index abd2155b1..53a6e0ff9 100644 --- a/app/Services/NotificationService.php +++ b/app/Services/NotificationService.php @@ -48,7 +48,6 @@ class NotificationService public function __construct(Server $server) { $this->server = $server; - $this->user = User::findOrFail($server->owner_id); } public function pass(array $notification)