Further enhancement with #9063a2a - to ensure our message addressing and content picks the right address
This commit is contained in:
@@ -90,7 +90,7 @@ class Tic extends FTNBase
|
||||
if (! $this->to)
|
||||
throw new \Exception('No to address defined');
|
||||
|
||||
$sysaddress = ($x=Setup::findOrFail(config('app.id'))->system)->match($this->to->zone)->first();
|
||||
$sysaddress = our_address($this->to->zone->domain,$this->to);
|
||||
|
||||
$result = collect();
|
||||
|
||||
@@ -233,7 +233,7 @@ class Tic extends FTNBase
|
||||
|
||||
// This should be one of my addresses
|
||||
case 'to':
|
||||
$ftns = Setup::findOrFail(config('app.id'))->system->addresses->pluck('ftn3d');
|
||||
$ftns = our_address()->pluck('ftn3d');
|
||||
|
||||
if (! ($ftns->contains($m[2])))
|
||||
throw new NotToMeException(sprintf('FTN Address [%s] not found or not one of my addresses',$m[2]));
|
||||
|
@@ -307,14 +307,14 @@ abstract class Protocol
|
||||
$addresses = collect();
|
||||
|
||||
foreach (($this->originate ? $this->node->aka_remote_authed : $this->node->aka_remote) as $ao)
|
||||
$addresses = $addresses->merge($this->setup->system->match($ao->zone,Address::NODE_ZC|Address::NODE_RC|Address::NODE_NC|Address::NODE_HC|Address::NODE_ACTIVE|Address::NODE_PVT|Address::NODE_POINT));
|
||||
$addresses = $addresses->merge(our_address($ao->zone->domain));
|
||||
|
||||
$addresses = $addresses->unique();
|
||||
|
||||
Log::debug(sprintf('%s:- Presenting limited AKAs [%s]',self::LOGKEY,$addresses->pluck('ftn')->join(',')));
|
||||
|
||||
} else {
|
||||
$addresses = $this->setup->system->addresses;
|
||||
$addresses = $this->setup->system->akas;
|
||||
|
||||
Log::debug(sprintf('%s:- Presenting ALL our AKAs [%s]',self::LOGKEY,$addresses->pluck('ftn')->join(',')));
|
||||
}
|
||||
|
Reference in New Issue
Block a user