More work to decommission rogue_path

This commit is contained in:
2023-09-15 22:57:32 +10:00
parent c1d6d48a3c
commit 708d9a9f67
12 changed files with 218 additions and 231 deletions

View File

@@ -6,7 +6,7 @@ use Illuminate\Console\Command;
use Illuminate\Database\QueryException;
use Illuminate\Support\Facades\DB;
use App\Models\Address;
use App\Models\{Address,System};
class AddressMerge extends Command
{
@@ -39,7 +39,7 @@ class AddressMerge extends Command
$src = Address::withTrashed()->findOrfail($this->argument('src'));
$dst = Address::withTrashed()->findOrfail($this->argument('dst'));
if ((! $this->option('ignore')) && ($src->system_id !== $dst->system_id) && ($src->system->name !== 'Discovered System')) {
if ((! $this->option('ignore')) && ($src->system_id !== $dst->system_id) && ($src->system->name !== System::default)) {
$this->error(sprintf('FTN addresses are from different systems (%s/%s)',$src->system->name,$dst->system->name));
exit(1);
}