From 5357746e6b5d4e849e03c22ecd5f4ceda5566314 Mon Sep 17 00:00:00 2001 From: drkthunder02 Date: Sat, 16 Feb 2019 02:06:22 -0600 Subject: [PATCH] command for moon mailer --- app/Library/Lookups/LookupHelper.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/Library/Lookups/LookupHelper.php b/app/Library/Lookups/LookupHelper.php index 39352db4e..0ac547a4d 100644 --- a/app/Library/Lookups/LookupHelper.php +++ b/app/Library/Lookups/LookupHelper.php @@ -24,9 +24,8 @@ class LookupHelper { $esi = new Eseye(); //Attempt to find the character name in the LookupCharacter table to see if we can match it to an id - $charId = CharacterToCorporation::where(['character_name' => $character])->get(['character_id']); - dd($charId); - if($charId == null) { + $char = CharacterToCorporation::where(['character_name' => $character])->get(['character_id']); + if(!isset($char->character_id)) { //Get the character id from the ESI API. $response = $esi->setQueryString([ 'categories' => 'character', @@ -38,7 +37,6 @@ class LookupHelper { return $response->character[0]; } else { - dd($charId); return $charId[0]->character_id; } }