auth47 bootstrapping

This commit is contained in:
HolgerHatGarKeineNode
2023-02-07 21:33:30 +01:00
parent f79ec131e3
commit 14936da92c
6 changed files with 187 additions and 33 deletions

View File

@@ -29,7 +29,11 @@ class LNUrlAuth extends Component
public function mount()
{
$this->k1 = bin2hex(str()->random(32));
$this->url = url('/api/lnurl-auth-callback?tag=login&k1='.$this->k1.'&action=login');
if (app()->environment('local')) {
$this->url = 'https://einundzwanzig.eu-1.sharedwithexpose.com/api/lnurl-auth-callback?tag=login&k1='.$this->k1.'&action=login';
} else {
$this->url = url('/api/lnurl-auth-callback?tag=login&k1='.$this->k1.'&action=login');
}
$this->lnurl = lnurl\encodeUrl($this->url);
$this->qrCode = base64_encode(QrCode::format('png')
->size(300)