From 6aeac4659cbd66491fc8f973020d73ad39c96e8d Mon Sep 17 00:00:00 2001 From: dev Date: Sat, 31 Oct 2026 09:12:19 +0000 Subject: [PATCH] Update features.py --- features.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/features.py b/features.py index 98dda3c..9846634 100644 --- a/features.py +++ b/features.py @@ -38,7 +38,6 @@ REACTION_EMOJI_RE = re.compile(r"^.{1,16}$") HEX_COLOR_RE = re.compile(r"^#[0-9a-fA-F]{6}$") PAGE_LINK_RE = re.compile(r"\]\((?:/teams/[^/]+/pages/)?([a-z0-9-]{1,48})\)", re.IGNORECASE) - def valid_hex_color(value: object) -> bool: return bool(isinstance(value, str) and HEX_COLOR_RE.fullmatch(value.strip())) @@ -112,7 +111,7 @@ def detect_website_brand(website: str) -> dict: return {"host": host, "brand": brand, "label": label} return {"host": host, "brand": "web", "label": "website"} - + def attachment_kind_from_name_and_mime( original_name: Optional[str], @@ -424,6 +423,8 @@ def user_can_see_last_active(settings_row, viewer: Optional[dict], target_user_i return False + + def page_payload(app_module, page, user: Optional[dict]) -> dict: can_read = bool( page["visibility"] == "public"