AddCharacterForeignKeysToRecognizes object
Object table AddCharacterForeignKeysToRecognizes in plugin/migrations/20261025130200_add_character_foreign_keys_to_recognizes.lua
Part of Recognize
Migration that adds foreign keys with ON DELETE CASCADE from the character_id and
target_id columns of the recognizes table to characters, along with an index on each
column, so that the database deletes the recognitions a character has and those of it
together with the character, also when the character is deleted along with its user. The
rows that name a character that does not exist are deleted first.
Summary
Methods
AddCharacterForeignKeysToRecognizes:down()
shared plugins/recognize/plugin/migrations/20261025130200_add_character_foreign_keys_to_recognizes.lua:22Removes the foreign keys and the indexes.
AddCharacterForeignKeysToRecognizes:up()
shared plugins/recognize/plugin/migrations/20261025130200_add_character_foreign_keys_to_recognizes.lua:13Deletes the recognitions of characters that do not exist, and adds the indexes and the foreign keys.