Merge pull request #2134 from bb2/patch-1
UI: Avoid redundant URL completion in CollectionsScene
This commit is contained in:
@@ -25,7 +25,7 @@ import { Collection, CollectionType, Permission } from "../models/collection.js"
|
||||
import { extract_title } from "../utils/collection_utils.js";
|
||||
import { collectionsCache } from "../utils/collections_cache.js";
|
||||
import { ErrorHandler } from "../utils/error.js";
|
||||
import { bytesToHumanReadable, completeHref, get_element, get_element_by_id } from "../utils/misc.js";
|
||||
import { bytesToHumanReadable, get_element, get_element_by_id } from "../utils/misc.js";
|
||||
import { UrlTextHandler } from "../utils/url_text.js";
|
||||
import { CreateEditCollectionScene } from "./CreateEditCollectionScene.js";
|
||||
import { DeleteConfirmationScene } from "./DeleteConfirmationScene.js";
|
||||
@@ -268,7 +268,7 @@ export class CollectionsScene {
|
||||
}
|
||||
contentcount_form.textContent = contentcount_form_txt;
|
||||
}
|
||||
let href = completeHref(collection.href);
|
||||
let href = window.location.origin + collection.href;
|
||||
new UrlTextHandler(url_form, copy_btn).setHref(href);
|
||||
download_btn.href = href;
|
||||
download_btn.onclick = (event) => {
|
||||
@@ -361,4 +361,4 @@ export class CollectionsScene {
|
||||
return this._principal_collection.displayname;
|
||||
else return this._user;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user