diff --git a/packages/primeng/src/confirmdialog/confirmdialog.ts b/packages/primeng/src/confirmdialog/confirmdialog.ts
index 83313e790d1..8b15d7e8969 100755
--- a/packages/primeng/src/confirmdialog/confirmdialog.ts
+++ b/packages/primeng/src/confirmdialog/confirmdialog.ts
@@ -74,7 +74,8 @@ const hideAnimation = animation([animate('{{transition}}', style({ transform: '{
@if (footer || footerTemplate) {
- } @else if (!footer && !footerTemplate) {
+ }
+ @if (!footer || !footerTemplate) {