PHP 8.2.30
Preview: buildFullPath.js Size: 783 B
//proc/thread-self/root/home/byroehnu/.trash/node_modules11/axios/lib/core/buildFullPath.js

'use strict';

import isAbsoluteURL from '../helpers/isAbsoluteURL.js';
import combineURLs from '../helpers/combineURLs.js';

/**
 * Creates a new URL by combining the baseURL with the requestedURL,
 * only when the requestedURL is not already an absolute URL.
 * If the requestURL is absolute, this function returns the requestedURL untouched.
 *
 * @param {string} baseURL The base URL
 * @param {string} requestedURL Absolute or relative URL to combine
 *
 * @returns {string} The combined full path
 */
export default function buildFullPath(baseURL, requestedURL, allowAbsoluteUrls) {
  let isRelativeUrl = !isAbsoluteURL(requestedURL);
  if (baseURL && (isRelativeUrl || allowAbsoluteUrls == false)) {
    return combineURLs(baseURL, requestedURL);
  }
  return requestedURL;
}

Directory Contents

Dirs: 0 × Files: 10

Name Size Perms Modified Actions
7.15 KB lrw-r--r-- 2026-02-20 03:53:00
Edit Download
2.45 KB lrw-r--r-- 2026-02-20 03:53:04
Edit Download
7.22 KB lrw-r--r-- 2026-02-20 03:53:04
Edit Download
783 B lrw-r--r-- 2026-02-20 03:53:06
Edit Download
2.14 KB lrw-r--r-- 2026-02-20 03:53:06
Edit Download
1.56 KB lrw-r--r-- 2026-02-20 03:53:06
Edit Download
3.49 KB lrw-r--r-- 2026-02-20 03:53:08
Edit Download
399 B lrw-r--r-- 2026-02-20 03:53:18
Edit Download
836 B lrw-r--r-- 2026-02-20 03:53:08
Edit Download
776 B lrw-r--r-- 2026-02-20 03:53:10
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).