mirror of
https://github.com/vastxie/99AI.git
synced 2025-09-18 01:36:37 +08:00
12 lines
331 B
JavaScript
12 lines
331 B
JavaScript
"use strict";
|
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
exports.formatUrl = void 0;
|
|
function formatUrl(url) {
|
|
let formattedUrl = url.replace(/\s+/g, '');
|
|
if (formattedUrl.endsWith('/')) {
|
|
formattedUrl = formattedUrl.slice(0, -1);
|
|
}
|
|
return formattedUrl;
|
|
}
|
|
exports.formatUrl = formatUrl;
|