Remove legacy sharing from frontend
This commit is contained in:
@@ -16,11 +16,9 @@
|
||||
# along with Radicale. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
import base64
|
||||
import copy # TODO: remove/3.7.0-final
|
||||
import io
|
||||
import json
|
||||
import logging
|
||||
import os # TODO: remove/3.7.0-final
|
||||
import re
|
||||
import socket
|
||||
import uuid
|
||||
|
||||
@@ -183,8 +183,7 @@ export class CollectionsScene {
|
||||
let share_info = get_element(node, "[data-name=shared-by]");
|
||||
let transformed_from = get_element(node, "[data-name=transformed-from]");
|
||||
let share = (shares || []).find(
|
||||
// TODO: Eventually remove the check for "bday"
|
||||
s => (s.ShareType === "map" || s.ShareType === "bday") &&
|
||||
s => (s.ShareType === "map") &&
|
||||
(s.PathOrToken || "").replace(/\/+$/, "") === (collection.href || "").replace(/\/+$/, ""));
|
||||
if (share) {
|
||||
if (share.Owner !== user) {
|
||||
|
||||
@@ -99,8 +99,7 @@ export class IncomingSharingScene {
|
||||
|
||||
let prefix = "/" + user + "/";
|
||||
let filtered_shares = shares.filter(
|
||||
// TODO: Eventually remove bday
|
||||
share => (share.ShareType === "map" || share.ShareType === "bday")
|
||||
share => (share.ShareType === "map")
|
||||
&& share.PathOrToken.startsWith(prefix));
|
||||
|
||||
if (filtered_shares.length === 0) {
|
||||
|
||||
@@ -225,8 +225,7 @@ function add_share_rows(user, password, collection, shares, errorHandler) {
|
||||
if (share["ShareType"] === "token") {
|
||||
add_share_row_node(user, password, collection, share, token_template, "share", delete_share_by_token, errorHandler);
|
||||
}
|
||||
// TODO: Eventually remove bday
|
||||
else if (share["ShareType"] === "map" || share["ShareType"] === "bday") {
|
||||
else if (share["ShareType"] === "map") {
|
||||
add_share_row_node(user, password, collection, share, map_template, "map", delete_share_by_map, errorHandler);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user