Icrc1Account constructor

Icrc1Account({
  1. required Principal owner,
  2. Uint8List? subaccount,
})

Implementation

Icrc1Account({required this.owner, Uint8List? subaccount}) : subaccount = subaccount == null ? Uint8List(32) : subaccount {

    if (this.subaccount.length != 32) { throw Exception('icrc1 subaccount must be 32-bytes'); }

    this['owner'] = this.owner;
    this['subaccount'] = Blob(this.subaccount);
}