Use regex for received file evaluation. Fixes recording received packet names

This commit is contained in:
2023-11-23 23:17:13 +11:00
parent 455fed52ee
commit 0800c48928
5 changed files with 14 additions and 10 deletions

View File

@@ -25,6 +25,8 @@ class Packet extends FTNBase implements \Iterator, \Countable
private const BLOCKSIZE = 1024;
protected const PACKED_MSG_LEAD = "\02\00";
public const regex = '([[:xdigit:]]{4})(?:-(\d{4,10}))?-(.+)';
public const PACKET_TYPES = [
'2.2' => FTNBase\Packet\FSC45::class,
'2+' => FTNBase\Packet\FSC48::class,