<?php
namespace App\Services;use App\Contracts\SmsGateway;
class LogSmsGateway implements SmsGateway {public function send(string $phone,string $message):void{\Log::info('sms.sent',['phone'=>substr($phone,0,4).'***'.substr($phone,-2),'message'=>preg_replace('/[A-Z2-9]{4}(?:-[A-Z2-9]{4}){2}/','[CODE_REDACTED]',$message)]);}}
