mirror of
git://f0xx.org/ac/ac-deploy
synced 2026-07-29 05:19:12 +03:00
cluster0: compose overlays lab-seed shortener; fix workspace git safe.dir
Re-copy ShortLinksRepository from NFS seed after ac-ms-* overlays; deploy-ac-workspace allows all safe.directory; verify-mail-lab logs short URL. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -29,10 +29,17 @@ final class AuthMailer {
|
||||
$subject = 'Verify your Android Cast account';
|
||||
$shortUrl = $verifyUrl;
|
||||
$qrImageUrl = null;
|
||||
if (class_exists('ShortLinksRepository', false)) {
|
||||
if (is_callable(['ShortLinksRepository', 'shortenForOutboundMail'])) {
|
||||
$pack = ShortLinksRepository::shortenForOutboundMail($verifyUrl, 86400);
|
||||
$shortUrl = (string) ($pack['short_url'] ?? $verifyUrl);
|
||||
$qrImageUrl = (string) ($pack['qr_image_url'] ?? '');
|
||||
if ($qrImageUrl === '' && preg_match('#/([a-f0-9]{6,16})$#', $shortUrl, $m)) {
|
||||
$qrImageUrl = preg_replace(
|
||||
'#/([a-f0-9]{6,16})$#',
|
||||
'/api/v1/qr/' . $m[1] . '.png',
|
||||
$shortUrl
|
||||
);
|
||||
}
|
||||
if ($qrImageUrl === '') {
|
||||
$qrImageUrl = null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user