We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
https://github.com/Jorijn/bitcoin-bolt11/blob/f339bfb531159583ea966f924c97de2f85402002/src/Encoder/PaymentRequestDecoder.php#L295
If you pass in a regtest invoice, it fails. If I add another the bcrt case, it seems to work fine:
switch ($bech32Prefix) { case 'bc': case 'bcrt': return new BitcoinMainnet(); case 'tb': return new BitcoinTestnet(); default: throw new UnknownNetworkVersionException('unknown network for invoice:' . $bech32Prefix); }
Although there might be a need for a new BitcoinRegtest class, but that's way above my knowledge
BitcoinRegtest
The text was updated successfully, but these errors were encountered:
Hi @eNzyOfficial
Would you be able to create a PR and include a unit test for this case?
Jorijn
Sorry, something went wrong.
Sorry for the slow reply, I'm a little busy to PR a unit test at the moment, I might be able to do it in a week or 2 when I've a little more time.
In the mean time, here is an example request if you'd like to write the test yourself:
https://lightningdecoder.com/lnbcrt5u1pj2lf33pp5ahahn2u3efqj8kwk28jcwxu0j3cclvscp0d32ufrvte5emhcflrqdqqcqzpgxqyz5vqsp5wd2n6ygajvlhflk7vx0eae6jrwp58fpunzwzlndswjlv4xndjuvs9qyyssqa4pa8g47p0fp0q7t9n0v3mpq64llvwjsvad9pzwk2djm2ncdvnl9usc3hc9mshv2gl3ksrx2e68agjwvhxu30fwcz8n5tvras99yvmcq228rh5
No branches or pull requests
https://github.com/Jorijn/bitcoin-bolt11/blob/f339bfb531159583ea966f924c97de2f85402002/src/Encoder/PaymentRequestDecoder.php#L295
If you pass in a regtest invoice, it fails. If I add another the bcrt case, it seems to work fine:
Although there might be a need for a new
BitcoinRegtest
class, but that's way above my knowledgeThe text was updated successfully, but these errors were encountered: