Fix panel domain lookup without site builder tables.
Deploy Ladill Hosting / deploy (push) Successful in 21s

Use user-owned domains only; the extracted hosting app does not have websites or website_members tables.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
isaacclad
2026-06-06 16:42:56 +00:00
co-authored by Cursor
parent 2cd55e1e44
commit 136d741b8e
@@ -1297,16 +1297,7 @@ class HostingPanelController extends Controller
->filter()
->all();
$websiteIds = Website::where('owner_user_id', $userId)->pluck('id')
->merge(WebsiteMember::where('user_id', $userId)->pluck('website_id'))
->unique()->values();
$domainRegistryHosts = Domain::where(function ($q) use ($userId, $websiteIds) {
$q->where('user_id', $userId);
if ($websiteIds->isNotEmpty()) {
$q->orWhereIn('website_id', $websiteIds);
}
})->pluck('host');
$domainRegistryHosts = Domain::where('user_id', $userId)->pluck('host');
$registeredDomains = RcServiceOrder::where('user_id', $userId)
->whereIn('order_type', [RcServiceOrder::TYPE_DOMAIN_REGISTRATION, RcServiceOrder::TYPE_DOMAIN_TRANSFER])