Why does this code snippet create a critical error on my site? [closed]

On this line in bulk_process_status_printed():

'ids' => join( $_REQUEST['post'], ',' ),

you’ve got the arguments backwards: it should be join(separator, array):

'ids' => join( ',', $_REQUEST['post'] ),

This is actually a PHP 8 change not WordPress 6

8.0.0 – Passing the separator after the array is no longer supported.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)