More complete rework of packet parsing and packet generation with 29710c
This commit is contained in:
@@ -253,14 +253,18 @@ class System extends Model
|
||||
* Return the packet that this system uses
|
||||
*
|
||||
* @param Address $ao
|
||||
* @param string|null $password
|
||||
* @return Packet
|
||||
*/
|
||||
public function packet(Address $ao): Packet
|
||||
public function packet(Address $ao,string $password=NULL): Packet
|
||||
{
|
||||
// @todo Check that the address is one of the system's addresses
|
||||
|
||||
return (new (collect(Packet::PACKET_TYPES)
|
||||
->get($this->pkt_type ?: config('fido.packet_default'))))->for($ao);
|
||||
return
|
||||
(new (collect(Packet::PACKET_TYPES)
|
||||
->get($this->pkt_type ?: config('fido.packet_default'))))
|
||||
->for($ao)
|
||||
->password($password);
|
||||
}
|
||||
|
||||
public function poll(): ?Job
|
||||
|
Reference in New Issue
Block a user