Skip to content

Commit

Permalink
Fixed omnibox error. The https:// protocol was missing.
Browse files Browse the repository at this point in the history
  • Loading branch information
00Fjongl committed Jul 9, 2024
1 parent 3d55281 commit 2e17d5a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions views/assets/js/common-16451543478.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ const omnibox = url =>
*/

// Another omnibox function. Unsure if the version above is needed.
const search = (input, template) => {
const search = (input, template = `https://${sx}%s`) => {
try {
// Return the input if it is already a valid URL.
// eg: https://example.com, https://example.com/test?q=param
Expand All @@ -85,10 +85,10 @@ const search = (input, template) => {
// Parse a URL to use with Ultraviolet.
const uvUrl = url => {
try {
url = location.origin + __uv$config.prefix + __uv$config.encodeUrl(search(url, sx + "%s"));
url = location.origin + __uv$config.prefix + __uv$config.encodeUrl(search(url));
} catch (e) {
// This is for cases where the Ultraviolet scripts have not been loaded.
url = search(url, sx + "%s");
url = search(url);
}
return url;
};
Expand Down Expand Up @@ -334,7 +334,7 @@ addEventListener("DOMContentLoaded", () => {
// setAuthCookie("__cor_auth=1", false);
ultraviolet: UrlHandler(uvUrl),

rammerhead: asyncUrlHandler(async (url) => location.origin + (await RammerheadEncode(search(url, sx + "%s")))),
rammerhead: asyncUrlHandler(async (url) => location.origin + (await RammerheadEncode(search(url)))),

searx: UrlHandler(location.protocol + `//c.${getDomain()}/engine/`),

Expand Down

0 comments on commit 2e17d5a

Please sign in to comment.