We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3de416d commit 45bcd17Copy full SHA for 45bcd17
lib/util/url.ts
@@ -44,8 +44,8 @@ export function resolve(from: string, to: string) {
44
* @returns
45
*/
46
export function cwd() {
47
- if (typeof window !== "undefined" && window.location) {
48
- return location.href;
+ if (typeof window !== "undefined" && window.location && window.location.href) {
+ return window.location.href;
49
}
50
51
if (typeof process !== "undefined" && process.cwd) {
0 commit comments