From a7c00467622b6545e315fc8728b348cf7557b82e Mon Sep 17 00:00:00 2001 From: trisua Date: Sun, 15 Jun 2025 18:22:29 -0400 Subject: [PATCH] fix: upload only post likes ui --- crates/app/src/public/html/components.lisp | 2 +- sql_changes/{posts_circle.sql => posts_stack.sql} | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) rename sql_changes/{posts_circle.sql => posts_stack.sql} (64%) diff --git a/crates/app/src/public/html/components.lisp b/crates/app/src/public/html/components.lisp index 1c87a44..7b7efcf 100644 --- a/crates/app/src/public/html/components.lisp +++ b/crates/app/src/public/html/components.lisp @@ -289,7 +289,7 @@ ("class" "flex gap-1 reactions_box") ("hook" "check_reactions") ("hook-arg:id" "{{ post.id }}") - (text "{% if post.context.reactions_enabled -%} {% if post.content|length > 0 -%} {{ self::likes(id=post.id, asset_type=\"Post\", likes=post.likes, dislikes=post.dislikes) }} {%- endif %} {%- endif %} {% if post.context.repost and post.context.repost.reposting -%}") + (text "{% if post.context.reactions_enabled -%} {% if post.content|length > 0 or post.uploads|length > 0 -%} {{ self::likes(id=post.id, asset_type=\"Post\", likes=post.likes, dislikes=post.dislikes) }} {%- endif %} {%- endif %} {% if post.context.repost and post.context.repost.reposting -%}") (a ("href" "/post/{{ post.context.repost.reposting }}") ("class" "button small camo") diff --git a/sql_changes/posts_circle.sql b/sql_changes/posts_stack.sql similarity index 64% rename from sql_changes/posts_circle.sql rename to sql_changes/posts_stack.sql index 9d8d312..9cd3474 100644 --- a/sql_changes/posts_circle.sql +++ b/sql_changes/posts_stack.sql @@ -1,5 +1,5 @@ ALTER TABLE posts -ADD COLUMN circle BIGINT NOT NULL DEFAULT 0; +DROP COLUMN circle; ALTER TABLE posts ADD COLUMN stack BIGINT NOT NULL DEFAULT 0;