mirror of
				https://github.com/mastodon/mastodon.git
				synced 2025-10-31 13:18:18 +00:00 
			
		
		
		
	 a59160cf01
			
		
	
	
		a59160cf01
		
			
		
	
	
	
		
			
	
		
	
	
		
			Some checks are pending
		
		
	
	Check i18n / check-i18n (push) Waiting to run
				
			CodeQL / Analyze (javascript) (push) Waiting to run
				
			CodeQL / Analyze (ruby) (push) Waiting to run
				
			Check formatting / lint (push) Waiting to run
				
			CSS Linting / lint (push) Waiting to run
				
			JavaScript Linting / lint (push) Waiting to run
				
			Ruby Linting / lint (push) Waiting to run
				
			JavaScript Testing / test (push) Waiting to run
				
			Historical data migration test / test (14-alpine) (push) Waiting to run
				
			Historical data migration test / test (15-alpine) (push) Waiting to run
				
			Ruby Testing / build (production) (push) Waiting to run
				
			Ruby Testing / build (test) (push) Waiting to run
				
			Ruby Testing / test (.ruby-version) (push) Blocked by required conditions
				
			Ruby Testing / test (3.1) (push) Blocked by required conditions
				
			Ruby Testing / test (3.2) (push) Blocked by required conditions
				
			Ruby Testing / Libvips tests (.ruby-version) (push) Blocked by required conditions
				
			Ruby Testing / Libvips tests (3.1) (push) Blocked by required conditions
				
			Ruby Testing / Libvips tests (3.2) (push) Blocked by required conditions
				
			Ruby Testing / End to End testing (.ruby-version) (push) Blocked by required conditions
				
			Ruby Testing / End to End testing (3.1) (push) Blocked by required conditions
				
			Ruby Testing / End to End testing (3.2) (push) Blocked by required conditions
				
			Ruby Testing / Elastic Search integration testing (.ruby-version, docker.elastic.co/elasticsearch/elasticsearch:7.17.13) (push) Blocked by required conditions
				
			Ruby Testing / Elastic Search integration testing (.ruby-version, docker.elastic.co/elasticsearch/elasticsearch:8.10.2) (push) Blocked by required conditions
				
			Ruby Testing / Elastic Search integration testing (.ruby-version, opensearchproject/opensearch:2) (push) Blocked by required conditions
				
			Ruby Testing / Elastic Search integration testing (3.1, docker.elastic.co/elasticsearch/elasticsearch:7.17.13) (push) Blocked by required conditions
				
			Ruby Testing / Elastic Search integration testing (3.2, docker.elastic.co/elasticsearch/elasticsearch:7.17.13) (push) Blocked by required conditions
				
			
		
			
				
	
	
		
			40 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Ruby
		
	
	
	
	
	
			
		
		
	
	
			40 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			Ruby
		
	
	
	
	
	
| # frozen_string_literal: true
 | |
| 
 | |
| class FixNotificationPermissionForeignKeys < ActiveRecord::Migration[7.1]
 | |
|   def up
 | |
|     safety_assured do
 | |
|       execute <<~SQL.squish
 | |
|         ALTER TABLE notification_permissions
 | |
|           DROP CONSTRAINT fk_rails_7c0bed08df,
 | |
|           ADD CONSTRAINT fk_rails_7c0bed08df
 | |
|             FOREIGN KEY (account_id)
 | |
|             REFERENCES accounts(id)
 | |
|             ON DELETE CASCADE,
 | |
| 
 | |
|           DROP CONSTRAINT fk_rails_e3e0aaad70,
 | |
|           ADD CONSTRAINT fk_rails_e3e0aaad70
 | |
|             FOREIGN KEY (from_account_id)
 | |
|             REFERENCES accounts(id)
 | |
|             ON DELETE CASCADE
 | |
|       SQL
 | |
|     end
 | |
|   end
 | |
| 
 | |
|   def down
 | |
|     safety_assured do
 | |
|       execute <<~SQL.squish
 | |
|         ALTER TABLE notification_permissions
 | |
|           DROP CONSTRAINT fk_rails_7c0bed08df,
 | |
|           ADD CONSTRAINT fk_rails_7c0bed08df
 | |
|             FOREIGN KEY (account_id)
 | |
|             REFERENCES accounts(id),
 | |
| 
 | |
|           DROP CONSTRAINT fk_rails_e3e0aaad70,
 | |
|           ADD CONSTRAINT fk_rails_e3e0aaad70
 | |
|             FOREIGN KEY (from_account_id)
 | |
|             REFERENCES accounts(id)
 | |
|       SQL
 | |
|     end
 | |
|   end
 | |
| end
 |