admin_post hook not working

You’re missing a ' in your code and your function name is different.

function my_maybe_add_redirect( $entry, $form ) {
    wp_redirect( 'https://www.google.com/', 301 );
    exit();
}
add_action( 'admin_post_submit_images', 'my_maybe_add_redirect', 10, 2 );

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