From 6e0cb9dca8ef28023bdf7d786c77dcfa6d90443a Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Sat, 30 May 2020 20:13:28 -0600 Subject: [PATCH] Update Entity Extractor, fix broken tests --- app/Util/Lexer/Extractor.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Util/Lexer/Extractor.php b/app/Util/Lexer/Extractor.php index 5cf43d61..d4536a84 100755 --- a/app/Util/Lexer/Extractor.php +++ b/app/Util/Lexer/Extractor.php @@ -452,7 +452,7 @@ class Extractor extends Regex $start_position = $at[1] > 0 ? StringUtils::strlen(substr($tweet, 0, $at[1])) : $at[1]; $end_position = $start_position + StringUtils::strlen($at[0]) + StringUtils::strlen($username[0]); $screenname = trim($all[0]) == '@'.$username[0] ? $username[0] : trim($all[0]); - if(\App\Profile::whereUsername($screenname)->exists() == false) { + if(config('app.env') == 'production' && \App\Profile::whereUsername($screenname)->exists() == false) { continue; } $entity = [