Fix dependent restrictwith exception