-
-
Notifications
You must be signed in to change notification settings - Fork 7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Record deleted(by mod) status to prevent re-appear #10732
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
db/schema.rb
is missing the new table, and app/models/redacted_status.rb
is missing the annotations.
Also, I wonder if it wouldn't be better to add a flag in the tombstones
table instead, to perform only one lookup instead of two.
Thanks for comment. I agree that using tombstone instead of making another table is performance better. |
Yes, I think I'd add a field to |
Oh that's seems good. |
They are added when running the migration in the development environment. Usually I add them manually 🤷 |
Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also, it looks like the migration script is missing, now.
db/schema.rb
Outdated
t.datetime "created_at", default: -> { "now()" }, null: false | ||
t.datetime "updated_at", default: -> { "now()" }, null: false | ||
t.datetime "created_at", default: -> { "CURRENT_TIMESTAMP" }, null: false | ||
t.datetime "updated_at", default: -> { "CURRENT_TIMESTAMP" }, null: false | ||
t.index ["account_id", "status_id"], name: "index_status_pins_on_account_id_and_status_id", unique: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not sure why these changes were made?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IDK too.. But db:migrate makes that.
* Record deleted(by mod) status to prevent re-appear * Move to Tombstone * Add missing migration script
* Record deleted(by mod) status to prevent re-appear * Move to Tombstone * Add missing migration script
* Record deleted(by mod) status to prevent re-appear * Move to Tombstone * Add missing migration script
Related: #10731
Like Tombstone, deleted status by moderation should not be re-appeared on timeline.