#!/bin/sh
[ "$1" != "upgrade" ] || exit 0
OPTS=""

if [ -n "$D" ]; then
    OPTS="--root=$D"
fi

if type systemctl >/dev/null 2>/dev/null; then
	if [ -z "$D" ]; then
		systemctl stop bfvcheck.service
	fi

	systemctl $OPTS disable bfvcheck.service
fi
