Use alternate method of determining URLs, consolidate logs format

This commit is contained in:
Cohee
2024-03-03 16:45:26 +02:00
parent 668d1f0fb9
commit 112e8f224c
2 changed files with 8 additions and 8 deletions

View File

@ -148,6 +148,7 @@ import {
getBase64Async,
humanFileSize,
Stopwatch,
isValidUrl,
} from './scripts/utils.js';
import { ModuleWorkerWrapper, doDailyExtensionUpdatesCheck, extension_settings, getContext, loadExtensionSettings, renderExtensionTemplate, runGenerationInterceptors, saveMetadataDebounced } from './scripts/extensions.js';
@ -9988,7 +9989,7 @@ jQuery(async function () {
const url = input.trim();
var request;
if (url.includes("https")) {
if (isValidUrl(url)) {
console.debug('Custom content import started for URL: ', url);
request = await fetch('/api/content/importURL', {
method: 'POST',