Correct way of adding taxonomy to a custom post type

I did some tests and it seems that we can use either one as long as the taxonomy or post type has been registered earlier in the script.

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