diff --git a/src/Datagrid/Pager.php b/src/Datagrid/Pager.php index 6de4e191f5..a0682ab9d5 100644 --- a/src/Datagrid/Pager.php +++ b/src/Datagrid/Pager.php @@ -589,10 +589,12 @@ public function isLastPage() */ public function getParameters() { - @trigger_error(sprintf( - 'The method "%s()" is deprecated since sonata-project/admin-bundle 3.84 and will be removed in 4.0.', - __METHOD__ - ), E_USER_DEPRECATED); + if ('sonata_deprecation_mute' !== (\func_get_args()[0] ?? null)) { + @trigger_error(sprintf( + 'The method "%s()" is deprecated since sonata-project/admin-bundle 3.84 and will be removed in 4.0.', + __METHOD__ + ), E_USER_DEPRECATED); + } return $this->parameters; }