Can’t access private custom posttype single- or archives-page

This seems like a similar question, but I’ll also put it here.

'has_archive' => 'richards'

Then flush permalinks (Settings > Permalinks).

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