Fixed force ssl schema for urls
Change-Id: I48cd4c06ac566520c6a91b46f57b635ce8e3b50d Signed-off-by: smarcet <smarcet@gmail.com>
This commit is contained in:
parent
eaaee95a76
commit
300c9fa1ea
|
@ -25,7 +25,8 @@ use Utils\Services\ICacheService;
|
|||
final class LaravelMailerHandler extends MailHandler
|
||||
{
|
||||
// seconds
|
||||
const TIME_BETWEEN_SAME_ERROR = 60 * 30;
|
||||
const TIME_BETWEEN_ERRORS = 60 * 30;
|
||||
const SENT_ERROR_EMAIL = 'SENT_ERROR_EMAIL';
|
||||
/**
|
||||
* The email addresses to which the message will be sent
|
||||
* @var array
|
||||
|
@ -141,13 +142,12 @@ final class LaravelMailerHandler extends MailHandler
|
|||
|
||||
// to avoid bloating inboxes/quotas
|
||||
if($this->cacheService){
|
||||
$footPrint = md5($subject.$content);
|
||||
if($this->cacheService->exists($footPrint)){
|
||||
if($this->cacheService->exists(self::SENT_ERROR_EMAIL)){
|
||||
// short circuit
|
||||
Log::debug(sprintf("LaravelMailerHandler::send skipping exception %s %s", $subject, $content));
|
||||
return;
|
||||
}
|
||||
$this->cacheService->setSingleValue($footPrint, $footPrint, LaravelMailerHandler::TIME_BETWEEN_SAME_ERROR);
|
||||
$this->cacheService->setSingleValue(self::SENT_ERROR_EMAIL, self::SENT_ERROR_EMAIL, LaravelMailerHandler::TIME_BETWEEN_ERRORS);
|
||||
}
|
||||
|
||||
foreach ($this->to as $to) {
|
||||
|
|
|
@ -20,6 +20,7 @@ use Sokil\IsoCodes\IsoCodesFactory;
|
|||
use Validators\CustomValidator;
|
||||
use App\Http\Utils\Log\LaravelMailerHandler;
|
||||
use Utils\Services\ICacheService;
|
||||
use Illuminate\Support\Facades\URL;
|
||||
/**
|
||||
* Class AppServiceProvider
|
||||
* @package App\Providers
|
||||
|
@ -34,6 +35,8 @@ class AppServiceProvider extends ServiceProvider
|
|||
public function boot()
|
||||
{
|
||||
|
||||
URL::forceScheme('https');
|
||||
|
||||
$logger = Log::getLogger();
|
||||
|
||||
foreach($logger->getHandlers() as $handler) {
|
||||
|
|
Loading…
Reference in New Issue