Remove previous emoji file on upgrade

This commit is contained in:
Bob Mottram 2018-02-08 12:25:40 +00:00
parent e17aebfa11
commit 2962ae0575
1 changed files with 1 additions and 1 deletions

View File

@ -637,7 +637,6 @@ function pleroma_add_emoji {
else else
sed -i "s|${shortcode},.*|${shortcode}, /emoji/${shortcode}.${image_extension}|g" $PLEROMA_DIR/config/emoji.txt sed -i "s|${shortcode},.*|${shortcode}, /emoji/${shortcode}.${image_extension}|g" $PLEROMA_DIR/config/emoji.txt
fi fi
cp $PLEROMA_DIR/config/emoji.txt $PLEROMA_DIR/config/emoji_prev.txt
chown -R pleroma:pleroma $PLEROMA_DIR chown -R pleroma:pleroma $PLEROMA_DIR
clear clear
@ -720,6 +719,7 @@ function upgrade_pleroma {
if [ -f $PLEROMA_DIR/config/emoji_prev.txt ]; then if [ -f $PLEROMA_DIR/config/emoji_prev.txt ]; then
cp $PLEROMA_DIR/config/emoji_prev.txt $PLEROMA_DIR/config/emoji.txt cp $PLEROMA_DIR/config/emoji_prev.txt $PLEROMA_DIR/config/emoji.txt
chown pleroma:pleroma $PLEROMA_DIR/config/emoji.txt chown pleroma:pleroma $PLEROMA_DIR/config/emoji.txt
rm cp $PLEROMA_DIR/config/emoji_prev.txt
fi fi
sudo -u pleroma mix deps.get sudo -u pleroma mix deps.get