Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
pleroma
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Alex Gleason
pleroma
Commits
f5f9197f
Commit
f5f9197f
authored
5 years ago
by
Roman Chvanikov
Browse files
Options
Downloads
Patches
Plain Diff
Add migration
parent
07a6f8b8
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
priv/repo/migrations/20191026191753_set_not_null_for_thread_mutes.exs
+17
-0
17 additions, 0 deletions
...grations/20191026191753_set_not_null_for_thread_mutes.exs
with
17 additions
and
0 deletions
priv/repo/migrations/20191026191753_set_not_null_for_thread_mutes.exs
0 → 100644
+
17
−
0
View file @
f5f9197f
defmodule
Pleroma
.
Repo
.
Migrations
.
SetNotNullForThreadMutes
do
use
Ecto
.
Migration
# modify/3 function will require index recreation, so using execute/1 instead
def
up
do
execute
(
"ALTER TABLE thread_mutes
ALTER COLUMN user_id SET NOT NULL,
ALTER COLUMN context SET NOT NULL"
)
end
def
down
do
execute
(
"ALTER TABLE thread_mutes
ALTER COLUMN user_id DROP NOT NULL,
ALTER COLUMN context DROP NOT NULL"
)
end
end
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment