my ($self, $expire) = @_;
$expire //= time + 60 * 60;
$hmackey //= random_bytes 512;
- hmac_sha1_base64 $self->id . " $expire " . $self->passphrase, $hmackey;
+ my $hmac = hmac_sha1_base64 $self->id . " $expire " . $self->passphrase, $hmackey;
+ wantarray ? ($hmac, $expire) : $hmac
}
1;