Skip to content

Remove redundant database indexes from channelables table#2323

Closed
Copilot wants to merge 4 commits into1.xfrom
copilot/sub-pr-2321-again
Closed

Remove redundant database indexes from channelables table#2323
Copilot wants to merge 4 commits into1.xfrom
copilot/sub-pr-2321-again

Conversation

Copy link

Copilot AI commented Oct 29, 2025

Removes duplicate index creation for channelable_type, channelable_id, and ends_at columns that already have indexes from existing migrations.

Changes Made

  • Removed redundant channelables indexes: channelable_type and channelable_id already have a composite index from Laravel's morphs() method
  • Removed ends_at index: Already indexed in 2022 migration add_starts_ends_at_to_channelables_table.php
  • Kept necessary indexes: enabled and starts_at on channelables, deleted_at on products/variants

The migration now only adds indexes for columns that actually need them, avoiding duplicate index creation while maintaining query performance improvements.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI changed the title [WIP] Add additional database indexes for improved query speed Remove redundant database indexes from channelables table Oct 29, 2025
Copilot AI requested a review from alecritson October 29, 2025 08:57
Base automatically changed from add_missing_database_indexes to 1.x October 29, 2025 09:26
@alecritson alecritson closed this Oct 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants