Skip to content

Commit c2f21a4

Browse files
authored
Fix subdomains
1 parent f46a25f commit c2f21a4

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

server.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -135,15 +135,15 @@ function valet_default_site_path($config)
135135
if (in_array($file, ['.', '..', '.DS_Store'])) continue;
136136

137137
// match dir for lowercase, because Nginx only tells us lowercase names
138-
if (strtolower($file) === $siteName) {
139-
$valetSitePath = $path.'/'.$file;
140-
break;
141-
}
142-
if (strtolower($file) === $domain) {
138+
if (strtolower($file) === $siteName || strtolower($file) === $domain) {
143139
$valetSitePath = $path.'/'.$file;
144140
}
145141
}
146142
closedir($handle);
143+
144+
if ($valetSitePath) {
145+
break;
146+
}
147147
}
148148
}
149149

0 commit comments

Comments
 (0)