Disable or enable registration within the pleroma frontend

This commit is contained in:
Bob Mottram 2017-11-06 22:10:54 +00:00
parent aa5feabc51
commit ea0af2d1e1
1 changed files with 6 additions and 2 deletions

View File

@ -363,8 +363,12 @@ function pleroma_disable_registrations {
--yesno $"\nDo you wish to disable new registrations?" 10 60
sel=$?
case $sel in
0) sed -i 's|registrations_open:.*|registrations_open: false|g' $PLEROMA_DIR/config/config.exs;;
1) sed -i 's|registrations_open:.*|registrations_open: true|g' $PLEROMA_DIR/config/config.exs;;
0) sed -i 's|registrations_open:.*|registrations_open: false|g' $PLEROMA_DIR/config/config.exs
sed -i 's|"registrationOpen":.*|"registrationOpen": false|g' $PLEROMA_DIR/priv/static/static/config.json
;;
1) sed -i 's|registrations_open:.*|registrations_open: true|g' $PLEROMA_DIR/config/config.exs
sed -i 's|"registrationOpen":.*|"registrationOpen": true|g' $PLEROMA_DIR/priv/static/static/config.json
;;
255) return;;
esac
pleroma_recompile