#!/bin/bash

phase="$1"
version="$2"

if [ "x$phase" = "xpost" ] && [ "x$version" = "x5.0-0" ]; then
	rm -f /etc/apt/preferences.d/99kopanotest.pref
	rm -f /etc/apt/preferences.d/99kopano.pref
fi


if [ -d /etc/php/7.3 ]; then
	# added for the upgrade to ucs 5.0
	a2dismod php7.0
	a2enmod php7.3
	# restart apache to apply changes
	systemctl restart apache2.service
fi
exit 0
