how to make has_block() see inside blocks too

It should, because has_block( 'gallery' ) uses source strpos() to determine if the post content has the <!-- wp:gallery string.

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