diff --git a/htdocs/compta/charges/index.php b/htdocs/compta/charges/index.php
index bd675dd1e19..3d6923905be 100644
--- a/htdocs/compta/charges/index.php
+++ b/htdocs/compta/charges/index.php
@@ -133,7 +133,7 @@ if ($year) {
print ''.$langs->trans("DescTaxAndDividendsArea").'
';
print "
";
-if (!empty($conf->tax->enabled) && $user->rights->tax->charges->lire) {
+if (isModEnabled('tax') && $user->rights->tax->charges->lire) {
// Social contributions only
print load_fiche_titre($langs->trans("SocialContributions").($year ? ' ('.$langs->trans("Year").' '.$year.')' : ''), '', '');
@@ -266,7 +266,7 @@ if (!empty($conf->tax->enabled) && $user->rights->tax->charges->lire) {
}
// VAT
-if (!empty($conf->tax->enabled) && $user->rights->tax->charges->lire) {
+if (isModEnabled('tax') && $user->rights->tax->charges->lire) {
print "
";
$tva = new Tva($db);