better chat name

pull/225/head
Aevann 2024-03-10 23:08:09 +02:00
parent df4e994a62
commit 2027103d23
2 changed files with 2 additions and 3 deletions

View File

@ -30,7 +30,7 @@ def chat_user(v, username):
if existing: if existing:
return redirect(f"/chat/{existing.id}") return redirect(f"/chat/{existing.id}")
chat = Chat(owner_id=v.id, name=f"Chat with @{user.username}") chat = Chat(owner_id=v.id, name=f"@{v.username}, @{user.username}")
g.db.add(chat) g.db.add(chat)
g.db.flush() g.db.flush()

View File

@ -457,7 +457,7 @@ CREATE TABLE public.chat_notifications (
CREATE TABLE public.chats ( CREATE TABLE public.chats (
id integer NOT NULL, id integer NOT NULL,
owner_id integer NOT NULL, owner_id integer NOT NULL,
name character varying(40) NOT NULL, name character varying(54) NOT NULL,
created_utc integer NOT NULL created_utc integer NOT NULL
); );
@ -3549,4 +3549,3 @@ ALTER TABLE ONLY public.comments
-- --
-- PostgreSQL database dump complete -- PostgreSQL database dump complete
-- --