kemono2/db/migrations/20231101_00_AMD325-add-key-dead-timestamp.py
2024-07-04 22:08:17 +02:00

15 lines
360 B
Python

"""
Add date key is made dead
"""
from yoyo import step
__depends__ = {"20230909_00_AUS5i6-new-index-for-post-get-prev-next"}
steps = [
step(
"""ALTER TABLE public.saved_session_keys_with_hashes ADD dead_at timestamp NULL;"""
"""UPDATE public.saved_session_keys_with_hashes SET dead_at = CURRENT_TIMESTAMP WHERE dead = true;"""
),
]